what is the output of the following program?
#include<stdio.h>
void main()
{
int x=4,y=3,z;
z=x-- -y;
printf("\n%d %d %d",x,y,z);
}
Answers were Sorted based on User's Feedback
Answer / poorna
Ans:3 3 1
bcoz
z=4-- -3; z=4-3;
z=1;
and x=3
there fore answer is 3 3 1
| Is This Answer Correct ? | 42 Yes | 5 No |
Answer / ravi chandra
x=4
y=3
z=x-- -y;
x-- means at first the left hand value will be equal to x
i.e., z=x and then the value of x gets decrement..
z=x-- -y
z=4-- -3
z=4-3 and x=x-1
z=1 and x=3
the y value remains same y=3
therefore x=3 y=3 and z=1
| Is This Answer Correct ? | 9 Yes | 0 No |
When reallocating memory if any other pointers point into the same piece of memory do you have to readjust these other pointers or do they get readjusted automatically?
write a c program for print your name .but,your name may be small letter mean print a capital letter or your name may be capital letter mean print a small letter .example \\enter ur name : sankar The name is: SANKAR (or) enter your name:SAnkar The name is:saNKAR
How do i store a paragraph into a string? for example, if i input a long paragraph, the program will read the words one by one and concatenate them until no word is left.
while initialization of array why we use a[][2] why not a[2][]...?
write function to reverse char array ... without using second array
5. What kind of sorting is this: SORT (k,n) 1.[Loop on I Index] repeat thru step2 for i=1,2,........n-1 2.[For each pass,get small value] min=i; repeat for j=i+1 to N do { if K[j]<k[min] min=j; } temp=K[i];K[i]=K[min];K[min]=temp; 3.[Sorted Values will be returned] A)Bubble Sort B)Quick Sort C)Selection Sort D)Merge Sort
What is c standard library?
Is array a primitive data type in c?
Write a program to know whether the input number is an armstrong number.
Declare the structure which contains the following members and write in C list of all students who score more than 75 marks. Roll No, Name, Father Name, Age, City, Marks.
What is the difference between macros and inline functions?
write a program to print the all 4digits numbers & whose squares must me even numbers?