what type of errors are checked during compilation
Answers were Sorted based on User's Feedback
Answer / rajasekharreddy
#include<stdio.h>
#define SIZE 10
int main()
{
int arr[SIZE],i,arr_Size,position;
printf("enter array size\t");
scanf("%d",&arr_Size);
printf("enter numbers\t");
for(i=0;i<arr_Size;i++)
{
scanf("%d",&arr[i]);
}
printf("before delete element\n");
for(i=0;i<arr_Size;i++)
{
printf("\t%d",arr[i]);
}
printf("\nenter position to delete\t");
scanf("%d",&position);
--position;
arr[position]=0;
for(i=position;i<(arr_Size-1);i++)
{
arr[i]=arr[i+1];
}
arr_Size--;
printf("after delete element\n");
for(i=0;i<arr_Size;i++)
{
printf("\t%d",arr[i]);
}
return 0;
}
Is This Answer Correct ? | 0 Yes | 3 No |
What is the difference between functions abs() and fabs()?
what is the output? #define fun(a,b,t) (g ##t=(a),(a)=(b),(b)=g##t) float gfloat; main() { float a=1.12,b=3.14; fun (a,b,float); printf("na=%4.2f,b=%4.2f",a,b); } A)Error in Defining Macro B)a=1.12,b=3.14 C)a=3.14,b=1.12 D)None of the Above
3 Answers Accenture, Infosys, Wipro,
What does sizeof return c?
How will you allocate memory to double a pointer?
What are the 4 types of programming language?
Determine if a number is a power of 2 at O(1).
Illustrate it summing the series 2+4+6+......to n terms using (i) while loop (ii) do-while loop
Write a C Programm.. we press 'a' , it shows the albhabetical number is 1, if we press 'g' it shows the answer 7.. any can help me
How do you use a pointer to a function?
Difference between exit() and _exit() function?
How does free() know how many bytes to free?
Is calloc better than malloc?