Search code examples
manpage

About the man usage


man 3p printf
man 3 printf

The above two man page gives different info of printf.

What's different for man 3 and man 3p?


Solution

  • $ man -k printf | grep '^printf'
    printf (1)           - format and print data
    printf (1posix)      - write formatted output
    printf (3)           - formatted output conversion
    printf (3posix)      - print formatted output
    

    You have probably installed the manpages-posix and manpages-posix-dev packages on your system, as I have. This also gives you the POSIX-prepared manpages, which is an excellent way to determine if you're relying on behavior specific to your system or standardized behavior.