Talk:File sequence

From Wikipedia, the free encyclopedia
Jump to: navigation, search
WikiProject Computing  
WikiProject icon This article is within the scope of WikiProject Computing, a collaborative effort to improve the coverage of computers, computing, and information technology on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.
 ???  This article has not yet received a rating on the project's quality scale.
 ???  This article has not yet received a rating on the project's importance scale.

Why does the article use the term "trailing zeros", when the zeros are clearly *leading*? The article uses the example conversion specification "%05d" for the C library function printf. The printf manpage describes the format this way:

Each conversion specification is introduced by the % character, after which the following appear in sequence: ...

  • Zero or more flags.
  • An optional minimum field width.
  • An optional precision.
  • An optional length modifier.
  • A conversion specifier.

The flag characters and their meanings are:...
0 For d, i, o, u, x, X, a, A, e, E, f, F, g, and G conversions, leading zeros are used to pad to the field width; no space padding is performed.

I propose that "trailing" should be replaced by "leading" throughout. Vanzandtj (talk) 13:28, 9 October 2009 (UTC)