Re: understanding format specifiers
- From: "Mike Wahler" <mkwahler@xxxxxxxxxxxx>
- Date: Tue, 30 Aug 2005 14:25:40 GMT
"siliconwafer" <spdandavate@xxxxxxxxx> wrote in message
news:1125405314.541569.279450@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> Hi All,
> What does a 'format specifier' do?
> Suppose I do,
> int a = 43; //decimal number
> printf("%x",a);
> I will get hex equivalent of 43.
> Does the format specifier do an implicit "decimal to hex" conversion
> before displaying ?
No. It does an explicit (stated with "%x") conversion from
binary to hex.
> Is it true for all format specifier?
Yes, all format specifiers cause a conversion from binary
to text.
-Mike
.
- References:
- understanding format specifiers
- From: siliconwafer
- understanding format specifiers
- Prev by Date: Re: How to free dynamically allocated array?
- Next by Date: Re: low-level question
- Previous by thread: Re: understanding format specifiers
- Next by thread: Re: understanding format specifiers
- Index(es):
Relevant Pages
|