for(i=1;i>0;i++);
printf("i=%d",i);
what will be the answer????
Answer Posted / guest
The value of i starts at 1 and increments from there. The
loop terminates when i <= 0.
For an unsigned value, this is only possible when i == 0.
For a signed value, incrementing a positive value by 1 will
eventually overflow within the binary word to become the
most negative value an integer can hold. The sequence is
thus (..., INT_MAX-1, INT_MAX, INT_MIN) and the loop
terminates, where INT_MAX and INT_MIN are the "most
positive" and "most negative" values for the word size used
on your machine.
Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
what are the facialities provided by you after the selection of the student.
Explain bitwise shift operators?
Explain what is wrong with this program statement? Void = 10;
What does node * mean?
What are terms in math?
How many types of operator or there in c?
Explain what header files do I need in order to define the standard library functions I use?
When do we get logical errors?
What does void main () mean?
Is sizeof a keyword in c?
Define the scope of static variables.
What is a pointer and how it is initialized?
How do you convert a decimal number to its hexa-decimal equivalent.Give a C code to do the same
Using functions, write a program that multiplies two arrays. Use the following functions: - Function ReadArray - Function MultiplyArrays - Function DisplayArrays
Are the variables argc and argv are always local to main?