Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!cs.utexas.edu!uunet!crdgw1!crdos1!davidsen From: davidsen@crdos1.crd.ge.COM (Wm E Davidsen Jr) Newsgroups: comp.std.c Subject: Re: printf zero-pads strings? Summary: How did you interpret Message-ID: <1430@crdos1.crd.ge.COM> Date: 24 Oct 89 19:09:37 GMT References: <7279@sdcsvax.UCSD.Edu> <20327@mimsy.umd.edu> Reply-To: davidsen@crdos1.UUCP (bill davidsen) Distribution: na Organization: GE Corp R&D Center Lines: 15 In article <20327@mimsy.umd.edu>, chris@mimsy.umd.edu (Chris Torek) writes: | The 4.4BSD doprnt.c (essentially the one I posted to comp.lang.c) prints | "0000x". This appears to conform to the letter of the standard (we wrote | the thing based on the letter of the standard!). I would be delighted if it workds that way, having a program which uses it (input strings are digit sequences with leading zeros stripped), now I ask you, what does "%-05x" give. I won't be on the machine with your doprint until Friday, thought you might remember. -- bill davidsen (davidsen@crdos1.crd.GE.COM -or- uunet!crdgw1!crdos1!davidsen) "The world is filled with fools. They blindly follow their so-called 'reason' in the face of the church and common sense. Any fool can see that the world is flat!" - anon