Re: printf *%f

Bert Wesarg <[email protected]>
Newsgroups gmane.linux.c-programming
Message-ID <[email protected]>
On Wed, Jan 12, 2011 at 08:39, ratheesh k <[email protected]> wrote:
> double x=45.9876 ;
>
> printf("%4.2f" , x); is working fine ...  But printf("%*f , 4.2 , x) ;

printf("%*.*f" , 4, 2 , x) ;

Bert

> behaves odd in my  fedora 8 pentium machine. any clue ?
>
> Does *  substitute only integers ?
>
>
> -Ratheesh
--
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.