Re: float

Michal Nazarewicz <[email protected]>
Newsgroups gmane.linux.c-programming
Message-ID <[email protected]>
> On 8/1/2010 19:11, Michal Nazarewicz wrote:
>> %lf is actually invalid format (though glibc will gladly treat it the
>>  same way it treats %f).  When passing a float value to a function with
>>  variable number of arguments it is promoted to double.

Nanakos Chrysostomos <[email protected]> writes:
> it could be then.
>
> printf("%f",(double)i);

Expect explicit cast is not required here as (in case of "..."
arguments) it is done implicitly as I described.

-- 
Best regards,                                         _     _
 .o. | Liege of Serenly Enlightened Majesty of      o' \,=./ `o
 ..o | Computer Science,  Michal "mina86" Nazarewicz   (o o)
 ooo +--<mina86*tlen.pl>--<jid:mina86*jabber.org>--ooO--(_)--Ooo--
--
To unsubscribe from this list: send the line "unsubscribe linux-c-programming" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.