Afficher un message
Vieux 18/10/2007, 01h41   #3
Tor Rustad
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: simple printf question

Bint wrote:
> Hi,
>
> I have a giant string buffer, and I want to print out small chunks of it at
> a time. How do I print out, say 20 characters of a string?
>
> Is it like this?
>
> printf("%20s",mystring);


printf("%.*s", len, mystring);


--
Tor <torust [at] online [dot] no>

C-FAQ: http://c-faq.com/
  Réponse avec citation
 
Page generated in 0,04422 seconds with 9 queries