int i,j;
for(i=0;i<=10;i++)
{
j+=5;
assert(i<5);
}
Answers were Sorted based on User's Feedback
Answer / susie
Answer :
Runtime error: Abnormal program termination.
assert failed (i<5), <file name>,<line number>
Explanation:
asserts are used during debugging to make sure that certain
conditions are satisfied. If assertion fails, the program
will terminate reporting the same. After debugging use,
#undef NDEBUG
and this will disable all the assertions from the
source code. Assertion
is a good debugging tool to make use of.
| Is This Answer Correct ? | 13 Yes | 2 No |
Answer / cmonkey
j has not been initialized, so j could hold any garbage.
Depending upon what was in j, assertion could pass or fail.
| Is This Answer Correct ? | 3 Yes | 0 No |
Who could write how to find a prime number in dynamic array?
what is oop?
main() { int i =0;j=0; if(i && j++) printf("%d..%d",i++,j); printf("%d..%d,i,j); }
Write a Program that Inputs 10 Numbers in an Array and Show the Maximum Number
main() { int i=0; for(;i++;printf("%d",i)) ; printf("%d",i); }
write a c program to Create employee record by taking details like name, employee id, address and phone number. While taking the phone number, take either landline or mobile number. Ensure that the phone numbers of the employee are unique. Also display all the details
void main() { while(1){ if(printf("%d",printf("%d"))) break; else continue; } }
Program to find the largest sum of contiguous integers in the array. O(n)
main() { int a=2,*f1,*f2; f1=f2=&a; *f2+=*f2+=a+=2.5; printf("\n%d %d %d",a,*f1,*f2); }
program to Reverse a linked list
12 Answers Aricent, Microsoft, Ness Technologies,
create a C-code that will display the total fare of a passenger of a taxi if the driver press enter,the timer will stop. Every 10 counts is 2 pesos. Initial value is 25.00
typedef struct error{int warning, error, exception;}error; main() { error g1; g1.error =1; printf("%d",g1.error); }