what is the value of b
if a=5;
b=++a + ++a
Answer Posted / sagar
here in b=++a + ++a;
a
Initial Value 5
First Prefix 6
Second Prefix 7
Final Equation b = 7 + 7 = 14...
So,correct answer is 14....
if the equation was as below:
c=++a;//a==6
d=++a;//a=7
b=c+d;//b=6+7=13
then b==13...
Is This Answer Correct ? | 96 Yes | 29 No |
Post New Answer View All Answers
When should a far pointer be used?
What is switch in c?
why wipro wase
How can a program be made to print the line number where an error occurs?
Can we use any name in place of argv and argc as command line arguments?
What does *p++ do?
What is a nested loop?
to print the salary of an employee according to follwing calculation: Allowances:HRA-20% of BASIC,DA-45% of BASIC,TA-10%. Deductions:EPF-8% of BASIC,LIC-Rs.200/-Prof.Tax:Rs.200/- create c language program?
Why array is used in c?
What does sizeof int return?
Why we use void main in c?
Describe newline escape sequence with a sample program?
What is class and object in c?
Do you know pointer in c?
Badboy is defined who has ALL the following properties: Does not have a girlfriend and is not married. He is not more than 23 years old. The middle name should be "Singh" The last name should have more than 4 characters. The character 'a' should appear in the last name at least two times. The name of one of his brothers should be "Ram" Write a method: boolean isBadBoy(boolean hasGirlFriend , boolean isMarried, int age , String middleName , String lastName , String[] brotherName); isHaveGirlFriend is true if the person has a girlfriend isMarried is true if the person is married age is the age of the person middleName is the middle name of the person lastName is the last name of the person brotherName is the array of the names of his brothers