main()
{
int i = 1;
int num[] = {1,2,3,4};
num[i] = i++;
printf("%d", num[i]);
}
what will be the output?
}
Answers were Sorted based on User's Feedback
Answer / mortal
num[i] is num[1] and its reassigned as i++ that is 1 thus it
will print 1.
but im not at all sure about this..
| Is This Answer Correct ? | 2 Yes | 10 No |
Answer / sathya
num[i]=i+1
num[1]=1+1=2, but num[1] is 1.so there is a error...
| Is This Answer Correct ? | 4 Yes | 13 No |
How do you redirect a standard stream?
Write a c program to demonstrate character and string constants?
What is Your Name :)
exit () is used to a) exit () terminates the execution of the program itself b) exit () terminates the execution of the loop c) exit () terminates the execution of the block d) none of the above
What is a file descriptor in c?
How is a macro different from a function?
How are structure passing and returning implemented?
program to find a smallest number in an array
a single linked list consists of nodes a to z .print the nodes in reverse order from z to a using recursion
What are the usage of pointer in c?
How is null defined in c?
how to find sum of 5 digits in C?