Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ zeropad(3C) — DG/UX 4.00

Media Vault

Software Library

Restoration Projects

Artifacts Sought



                                                              zeropad(3C)



        _________________________________________________________________
        zeropad                                                  function
        Substitute zeros for leading spaces.
        _________________________________________________________________


        Calling Sequence

        char *digs, *zeropad();
        digs = zeropad(digs);

        where digs is a byte pointer to a character array.


        Description

        Use the zeropad function if you want to substitute zeros for any
        leading spaces in a character array.


        Returns

        The zeropad function returns the argument digs.


        Related Functions

        See also the zero function.


        Example

        /* Program test for the zeropad() function */

        char  digs[] = "      7";

        main() {
            printf("%s\n", digs);
            zeropad(digs);
            printf("%s\n", digs);
        }

        A call to the program test generates the output

        7
        0000007








        DG/UX 4.00                                                 Page 1
               Licensed material--property of copyright holder(s)



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026