printf

PRINTF(1)                          ç¨æ¶å½ä»¤                         PRINTF(1)



å稱
       printf - æ ¼å¼å並顯示æ¸æ

æ¦è¿°
       printf æ ¼å¼[åæ¸å表]...
       printf é¸é

æè¿°
       æç§æå®æ ¼å¼æå°åæ¸å表ä¸çåæ¸ææç§é¸é å·è¡ï¼

       --help 顯示æ¤å¹«å©ä¿¡æ¯ä¸¦éåº

       --version
              顯示çæ¬ä¿¡æ¯ä¸¦éåº

       æ ¼å¼ä»¥ C printf çæ¹å¼æ§å¶è¼¸åºãè½ç¾©åºåå¦ä¸ï¼

       \"     éå¼è

       \\     åæç·

       \a     å ±è¦ç¬¦(BEL)

       \b     éæ ¼ç¬¦

       \c     ç¦æ¢å°¾é¨çæè¡ç¬¦

       \e     escape å符

       \f     æé 符

       \n     å¦èµ·ä¸è¡

       \r     åå°è¡é¦

       \t     水平製表符

       \v     åç´è£½è¡¨ç¬¦

       \NNN   åç¯æ¸ä»¥å«é²å¶æ¸ NNN (1è³3ä½)表示

       \xHH   åç¯æ¸ä»¥ååé²å¶æ¸ HH (1è³2ä½)表示

       \uHHHH Unicode (ISO/IEC 10646) å符ï¼æ¯ 16é²å¶å¼ HHHHï¼4ä½ï¼

       \UHHHHHHHH
              Unicode å符ï¼æ¯ 16é²å¶å¼ HHHHHHHHï¼8ä½ï¼

       %%     å®å %

       %b     åæ¸å表ä½ç²å符串ï¼å¶ä¸ '\' å‐
              符被è½ç¾©ï¼é¤äºå«é²å¶è½ç¾©æ ¼å¼è®ç² \0 æ \0NNN

       %q     åæ¸å表以ä¸ç¨®å¯è¢« shell 輸åºéæ°è®åçæ ¼å¼é²è¡è¼¸åºï¼ä¸¦ä½¿ç¨
              POSIX 建è°ç  $” èªæ³å°ä¸å¯æå°å符é²è¡è½ç¾©ã

       並ä¸ææ C æ ¼å¼è¦ç¯çè½ç¾©å°ç± diouxXfeEgGcs ä¸çæåå‐
       符ä½ç²çµæï¼ä¸âåæ¸å表âå°è¢«é¦åè½æç²é©ç¶çæ ¼å¼ãè®é寬度è²æä¹æ被èçã

       注æï¼æ¨ç shell å¯è½å§ç½®äºèªå·±ç printf
       ç¨åºçæ¬ï¼å®é常æè¦èéè£ææåçç¸æçæ¬ãè«æ¥é±æ¨ç shell ææªç²ç¥å®ææ¯æçé¸é ã

ä½è
       ç± David MacKenzie 編寫ã

å ±åé¯èª¤
       GNU coreutils çå¨ç·å¹«å©ï¼ <http://www.gnu.org/software/coreutils/>
       è«å <http://translationproject.org/team/zh_CN.html> å ±å printf çç¿»è‐
       ¯é¯èª¤ã

çæ¬
       Copyright © 2017 Free Software Foundation, Inc.  License GPLv3+: GNU
       GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
       This is free software: you are free to change and redistribute it.
       There is NO WARRANTY, to the extent permitted by law.

åè¦
       printf(3)

       å®æ´ææªè«è¦ï¼ <http://www.gnu.org/software/coreutils/printf>
       æèå¨æ¬å°ä½¿ç¨ï¼ info '(coreutils) printf invocation'

è·
       æ¬é é¢ä¸æçç±ä¸æ man æåé è¨åæä¾ã
       ä¸æ man æåé è¨åï¼https://github.com/man-pages-zh/manpages-zh



GNU coreutils 8.28                2017å¹´10æ                         PRINTF(1)