what is the difference between %d and %*d in c languaga?
Answer Posted / sivakumar
anand and manini your expectations are wrong. because %d
give the original value of the variable and %*d give the
address of the variable.
eg:-
int a=10,b=20;
printf("%d%d",a,b);
printf("%*d%*d",a,b);
result is 10 20 1775 1775
here 1775 is the starting address of the memory allocation
for the integer.a and b having same address because of
contagious memory allocation.
Is This Answer Correct ? | 35 Yes | 19 No |
Post New Answer View All Answers
Write an efficient algo and C code to shuffle a pack of cards.. this one was a feedback process until we came up with one with no extra storage.
Wt are the Buses in C Language
Why & is used in scanf in c?
Why array is used in c?
Is null equal to 0 in sql?
Why n++ execute faster than n+1 ?
How does selection sort work in c?
What is bss in c?
Which driver is a pure java driver
Is using exit() the same as using return?
What are the basic data types associated with c?
What is a char c?
"%u" unsigned integer print the a) address of variable b) value of variable c) name of a variable d) none of the above
Explain setjmp()?
How can I manipulate individual bits?