Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the difference between %d and %*d in C

Answer Posted / meruva

%d means it prints only given value,
and %*d means it prints garbage value.
for eg: //it prints i value is=10
int i=10;
printf("i value is=%d",i);

//it prints garbage value
int i=10;
printf("i value is=%*d",i);

Is This Answer Correct ?    5 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why pointers are used?

1084


Can a pointer be volatile in c?

1003


Can include files be nested?

1129


What are the c keywords?

1212


What is the difference between functions abs() and fabs()?

1168


What is array within structure?

1138


Which are low level languages?

1114


What are the standard predefined macros?

1156


Write a code to remove duplicates in a string.

1055


What is d scanf?

1103


What is else if ladder?

1033


Difference between Shallow copy and Deep copy?

2037


Here is a neat trick for checking whether two strings are equal

1031


Why is this loop always executing once?

1070


Explain Function Pointer?

1190