Find errors
(1) m = ++a*5;
(2) a = b ++ -c*2;
(3)y = sqrt (1000);
Answer Posted / anand
1. compiler gives syntax error there should be any space
between increment or decrement operators and the variable.
2. even if some compilers accept this, then b++ - c*2 is
considered where c*2 is subtracted from the present value of
variable b and after that the value in variable b is
decremented by 1.
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
What is a file descriptor in c?
What does emoji p mean?
1. Write a function to display the sum of two numbers in the following ways: By using (i) pass by value (ii) pass by address a. function with argument and with return value b. function with argument and without return value c. without argument , with return value d. without argument , without return value Note: Use pass by address.
How do I use strcmp?
What is clrscr ()?
Explain modulus operator. What are the restrictions of a modulus operator?
Write a simple code fragment that will check if a number is positive or negative.
Explain null pointer.
i have to apply for the rbi for the post of officers. i need to know abt the entrance questions whether it may be aps or techinical....
Is using exit() the same as using return?
A SIMPLE PROGRAM OF GRAPHICS AND THEIR OUTPUT I WANT SEE WAHAT OUTOUT OF GRAPHICS PROGRAM
Define and explain about ! Operator?
What are the types of functions in c?
What does typedef struct mean?
Write a program that accept anumber in words