{"id":114298,"date":"2026-10-08T22:32:45","date_gmt":"2026-10-08T14:32:45","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/114298.html"},"modified":"2026-10-08T22:32:45","modified_gmt":"2026-10-08T14:32:45","slug":"p1-%e4%bb%80%e4%b9%88%e6%98%afuc%ef%bc%9f%e6%93%8d%e4%bd%9c%e7%b3%bb%e7%bb%9f%e7%9a%84%e5%8e%86%e5%8f%b2","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/114298.html","title":{"rendered":"p1-\u4ec0\u4e48\u662fUC\uff1f\u64cd\u4f5c\u7cfb\u7edf\u7684\u5386\u53f2"},"content":{"rendered":"<h2>\u4e00&#xff0c;\u4ec0\u4e48\u662fUC&#xff1f;<\/h2>\n<p>U\u662f\u6307unix\u64cd\u4f5c\u7cfb\u7edf\u3002Unix\u64cd\u4f5c\u7cfb\u7edf\u662f\u4f7f\u7528C\u8bed\u8a00\u5b9e\u73b0\u7684\u7cfb\u7edf\u7ea7\u8f6f\u4ef6\u3002<br \/>\nC\u662f\u6307C\u8bed\u8a00&#xff0c;\u5c31\u662f\u5927\u5bb6\u4e0a\u95e8\u8bfe\u7a0b\u5b66\u4e60\u7684\u8bed\u8a00\u3002<br \/>\nUC\u662f\u6307\u4f7f\u7528C\u8bed\u8a00\u5728\u64cd\u4f5c\u7cfb\u7edfUnix\u4e0a\u7684\u7528\u6237\u7f16\u7a0b\u3002unix\u7cfb\u7edf\u5411\u7528\u6237\u63d0\u4f9b\u4e86\u5927<br \/>\n\u91cf\u7684\u63a5\u53e3\u3002\u7528\u6237\u901a\u8fc7\u7cfb\u7edf\u63d0\u4f9b\u7684\u63a5&#xff0c;\u4f7f\u7528\u64cd\u4f5c\u7cfb\u7edf\u63d0\u4f9b\u7684\u670d\u52a1\u3002<br \/>\n\u60f3\u8981\u5199\u51fa\u529f\u80fd\u5f3a\u5927\u7684\u7a0b\u5e8f&#xff0c;\u4e00\u5b9a\u8981\u501f\u52a9\u64cd\u4f5c\u7cfb\u7edf\u63d0\u4f9b\u7684\u529f\u80fd\u3002<br \/>\n\u6bd4\u5982&#xff1a;\u7f51\u7edc\u901a\u4fe1&#xff0c;\u8fdb\u7a0b\u7ba1\u7406&#xff0c;\u7ebf\u7a0b\u7ba1\u7406\u7b49\u3002<\/p>\n<h2>\u4e8c\u3001Unix\u80cc\u666f\u4ecb\u7ecd<\/h2>\n<p>1961-1969:\u53f2\u524d\u65f6\u4ee3<br \/>\nCTSS(CompatibleTime-Sharing System&#xff0c;\u517c\u5bb9\u5206\u65f6\u7cfb\u7edf)&#xff0c;\u4ee5MIT\u4e3a\u9996\u7684\u5f00\u53d1\u5c0f\u7ec4&#xff0c;\u5c0f\u800c\u7b80\u5355\u7684\u5b9e\u9a8c\u5ba4\u539f\u578b\u3002<br \/>\nMultics(Multiplexed Information and Computing System,\u591a\u8def\u4fe1\u606f\u4e0e\u8ba1\u7b97\u7cfb\u7edf&#xff09;&#xff0c;\u5e9e\u5927\u800c\u590d\u6742&#xff0c;\u4e0d\u582a\u91cd\u8d1f\u3002<br \/>\nUnics(Uniplexed information and Computing System,\u5355\u8def\u4fe1\u606f\u4e0e\u8ba1\u7b97\u7cfb\u7edf&#xff09;&#xff0c;\u8fd4\u749e\u5f52\u771f&#xff0c;\u8d70\u4e0a\u6b63\u9053\u3002<\/p>\n<p>1969-1971&#xff1a;\u521b\u4e16\u7eaa<br \/>\n1969\u5e74&#xff0c;AT&amp;T\u9000\u51fa\u4e86Multics\u9879\u76ee&#xff0c;\u6765\u81ea\u8d1d\u5c14\u5b9e\u9a8c\u5ba4\u7684Ken Thompson\u4e3a\u4e86\u5728PDP-7\u4e0a\u5b9e\u73b0\u4ed6\u7684\u661f\u9645\u65c5\u884c\u6e38\u620f&#xff0c;\u7f16\u5199\u4e86\u4e00\u7cfb\u5217\u5b9e\u7528\u7a0b\u5e8f&#xff0c;\u6210\u4e3a\u540e\u6765Unix\u7cfb\u7edf\u7684\u6838\u5fc3<br \/>\n1970\u5e74&#xff0c;KenThompson\u5728BCFL\u8bed\u8a00\u7684\u57fa\u7840\u4e0a\u53d1\u660e\u4e86B\u8bed\u8a00&#xff0c;\u5f53\u65f6\u7684Unix\u7cfb\u7edf\u7528\u6c47\u7f16\u8bed\u8a00\u548cB\u8bed\u8a00\u6df7\u5408\u7f16\u5199<br \/>\n1971\u5e74&#xff0c;\u7b2c\u4e00\u4e2aUnix\u5e94\u7528\u7a0b\u5e8fnroff\u8bde\u751f&#xff0c;\u4e3a\u8d1d\u5c14\u5b9e\u9a8c\u5ba4\u7684\u6587\u5b57\u5904\u7406\u5de5\u4f5c\u63d0\u4f9b\u652f\u6301&#xff0c;Unix\u7cfb\u7edf\u5f00\u59cb\u5411PDP-11\u79fb\u690d<\/p>\n<p>1971-1979:\u51fa\u8c37\u8bb0<br \/>\n1971\u5e74&#xff0c;DennisRitchie\u5728B\u8bed\u8a00\u7684\u57fa\u7840\u4e0a\u53d1\u660e\u4e86C\u8bed\u8a00<br \/>\n1973\u5e74&#xff0c;DennisRitchie\u7528C\u8bed\u8a00\u91cd\u5199\u4e86\u6574\u4e2aUnix\u7cfb\u7edf&#xff0c;\u6781\u5927\u5730\u63d0\u5347\u4e86Unix\u7cfb\u7edf\u7684\u53ef\u8bfb\u6027\u3001\u53ef\u7ef4\u62a4\u6027\u548c\u53ef\u79fb\u690d\u6027<br \/>\n1974\u5e74&#xff0c;Ritchie\u548cThompson\u5728\u300a\u7f8e\u56fd\u8ba1\u7b97\u673a\u901a\u4fe1\u300b\u4e0a\u53d1\u8868\u8bba\u6587&#xff0c;\u7b2c\u4e00\u6b21\u516c\u5f00\u5c55\u793aUnix<br \/>\n1979\u5e74&#xff0c;\u8d1d\u5c14\u5b9e\u9a8c\u5ba4\u53d1\u5e03UnixV7\u7248\u672c&#xff0c;\u6210\u4e3aUnix\u4e16\u754c\u516c\u8ba4\u7684\u7b2c\u4e00\u4e2a\u771f\u6b63\u610f\u4e49\u4e0a\u7684Unix\u64cd\u4f5c\u7cfb\u7edf<\/p>\n<p>1980-1985:\u7b2c\u4e00\u6b21Unix\u6218\u4e89<br \/>\n1980\u5e74&#xff0c;\u7f8e\u56fd\u56fd\u9632\u90e8\u9ad8\u7ea7\u7814\u7a76\u8ba1\u5212\u5c40&#xff08;DARPA&#xff09;\u51b3\u5b9a\u5728\u52a0\u5dde\u5927\u5b66\u4f2f\u514b\u5229\u5206\u6821\u5f00\u53d1\u7684BSD Unix\u4e0a\u5b9e\u73b0TCP\/iIP\u534f\u8bae\u6808<br \/>\n1983\u5e74&#xff0c;AT&amp;T\u7684\u62c6\u5206\u4f7f\u5176\u5f97\u4ee5\u5c06UnixSystemV\u5546\u4e1a\u5316<br \/>\n1984\u5e74&#xff0c;\u7b2c\u4e00\u6b21Unix\u6218\u4e89\u5728AT&amp;T\u7684Unix SystemV\u548c\u4f2f\u514b\u5229\u7684BSD Unix\u4e4b\u95f4\u5168\u9762\u7206\u53d1<br \/>\n1985\u5e74&#xff0c;\u4ee5IEEEPOSIX\u4e3a\u6838\u5fc3\u7684\u4e00\u7cfb\u5217\u6280\u672f\u6807\u51c6\u6700\u7ec8\u5f25\u5408\u4e86UnixSystemV\u548cBSDUnix\u4e4b\u95f4\u7684\u88c2\u75d5<\/p>\n<p>1988-1990&#xff1a;\u7b2c\u4e8c\u6b21Unix\u6218\u4e89<br \/>\n1988\u5e74&#xff0c;AT&amp;T\u6301\u6709Sun\u516c\u53f820%\u7684\u80a1\u4efd&#xff0c;\u5ba3\u544a\u4e24\u5bb6\u516c\u53f8\u6b63\u5f0f\u8054\u59fb<br \/>\n1989\u5e74&#xff0c;IBM\u3001DEC\u3001HP\u7b49\u4e8c\u7ebf\u5382\u5546\u521b\u5efa\u5f00\u653e\u8f6f\u4ef6\u57fa\u91d1\u4f1a&#xff08;OSF&#xff09;\u5e76\u7ed3\u6210\u76df\u53cb&#xff0c;\u4ee5\u4e0eAT&amp;T\/Sun\u8f74\u5fc3\u5bf9\u6297&#xff0c;\u7b2c\u4e8c\u6b21Unix\u6218\u4e89\u7206\u53d1<br \/>\n1990\u5e74&#xff0c;Windows3.0\u53d1\u5e03&#xff0c;Unix\u4e16\u754c\u4ece\u9163\u6218\u4e2d\u5e61\u7136\u9192\u609f&#xff0c;\u5d2d\u65b0\u7684\u5e1d\u56fd\u6b63\u5728\u5d1b\u8d77&#xff0c;\u771f\u6b63\u7684\u654c\u4eba\u6765\u81eaRedmond<\/p>\n<p>1991-2000&#xff1a;\u5c18\u57c3\u843d\u5b9a<br \/>\n1991\u5e74&#xff0c;\u82ac\u5170\u5927\u5b66\u751fLinusTorvalds\u5ba3\u5e03\u4e86Linux\u9879\u76ee<br \/>\n1993\u5e74&#xff0c;Linux\u5df2\u8fbe\u5230\u4ea7\u54c1\u7ea7\u64cd\u4f5c\u7cfb\u7edf\u7684\u6c34\u51c6<br \/>\n1993\u5e74&#xff0c;AT&amp;T\u5c06Unix\u7cfb\u7edf\u5b9e\u9a8c\u5ba4\u5356\u7ed9\u4e86Novell<br \/>\n1994\u5e74&#xff0c;Novell\u5c06Unix\u5546\u6807\u5356\u7ed9\u4e86X\/Open\u6807\u51c6\u7ec4<br \/>\n1995\u5e74&#xff0c;Novell\u5c06UnixWare\u5356\u7ed9\u4e86SCO<br \/>\n2000\u5e74&#xff0c;SCO\u5c06Unix\u6e90\u7801\u5356\u7ed9\u4e86CalderaLinux\u53d1\u884c\u5546<\/p>\n<h2>\u4e09\u3001Linux\u80cc\u666f\u4ecb\u7ecd<\/h2>\n<h3>\u5b83\u662f\u5565<\/h3>\n<p>Linux\u662f\u4e00\u6b3e\u7c7bUnix\u64cd\u4f5c\u7cfb\u7edf&#xff0c;\u514d\u8d39\u5f00\u6e90&#xff0c;Linux\u7684\u4e0d\u540c\u53d1\u884c\u7248\u672c\u90fd\u4f7f\u7528\u76f8\u540c\u7684\u5185\u6838<br \/>\nLinux\u53ef\u4ee5\u8fd0\u884c\u5728\u624b\u673a\u3001\u5e73\u677f\u3001\u8def\u7531\u5668\u3001\u89c6\u9891\u6e38\u620f\u63a7\u5236\u5668\u3001\u4e2a\u4eba\u7535\u8111\u3001\u5927\u578b\u8ba1\u7b97\u673a\u3001\u8d85\u7ea7\u8ba1\u7b97\u673a\u7b49\u591a\u79cd\u786c\u4ef6\u5e73\u53f0\u4e0a<br \/>\n\u4e25\u683c\u610f\u4e49\u4e0a\u7684Linux\u4ec5\u6307\u64cd\u4f5c\u7cfb\u7edf\u5185\u6838&#xff0c;\u4f46\u4e00\u822c\u88ab\u7528\u4e8e\u6307\u79f0\u67d0\u4e2a\u5177\u4f53\u7684\u53d1\u884c\u7248\u672c<br \/>\nLinux\u96b6\u5c5e\u4e8eGNU\u5de5\u7a0b&#xff0c;\u6574\u5957GNU\u5de5\u5177\u5305\u4ece\u4e00\u5f00\u59cb\u5c31\u5185\u7f6e\u5176\u4e2d&#xff0c;\u53ef\u63d0\u4f9b\u9ad8\u8d28\u91cf\u7684\u5f00\u53d1\u5de5\u5177<br \/>\nLinux\u7684\u53d1\u660e\u4eba\u662fLinusTorvalds&#xff0c;\u540c\u65f6\u4ed6\u4e5f\u662fLinux\u5546\u6807\u7684\u5408\u6cd5\u6301\u6709\u8005<\/p>\n<h3>Linux\u7cfb\u7edf\u7684\u7279\u70b9<\/h3>\n<p>\u9075\u5faaGNU\/GPL<br \/>\n\u5f00\u653e\u6027<br \/>\n\u591a\u7528\u6237<br \/>\n\u591a\u4efb\u52a1<br \/>\n\u8bbe\u5907\u72ec\u7acb\u6027<br \/>\n\u4e30\u5bcc\u7684\u7f51\u7edc\u529f\u80fd<br \/>\n\u53ef\u9760\u7684\u7cfb\u7edf\u5b89\u5168<br \/>\n\u826f\u597d\u7684\u53ef\u79fb\u690d\u6027<\/p>\n<h2>\u56db&#xff0c;Linux\u7684\u53d1\u884c\u7248\u672c<\/h2>\n<p>\u5927\u4f17\u7684Ubuntu<br \/>\n\u4f18\u96c5\u7684Linux Mint<br \/>\n\u9510\u610f\u7684Fedora<br \/>\n\u534e\u4e3d\u7684openSUSE<br \/>\n\u81ea\u7531\u7684Debian<br \/>\n\u7b80\u6d01\u7684Slackware<br \/>\n\u8001\u724c\u7684RedHat<\/p>\n<h2>\u4e94\u3001\u8ba1\u7b97\u673a\u7cfb\u7edf\u5206\u5c42<\/h2>\n<h3>\u4ec0\u4e48\u662f\u64cd\u4f5c\u7cfb\u7edf&#xff1f;<\/h3>\n<p>\u64cd\u4f5c\u7cfb\u7edf\u662f\u7ba1\u7406\u8ba1\u7b97\u673a\u786c\u4ef6\u8d44\u6e90\u548c\u8f6f\u4ef6\u8d44\u6e90\u7684\u4e00\u6b3e\u7cfb\u7edf\u8f6f\u4ef6\u3002\u64cd\u4f5c\u7cfb\u7edf\u7b80\u79f0OS\u3002<\/p>\n<p>\u5b66\u4e60\u5185\u5bb9<\/p>\n<p>\u5e93\u6587\u4ef6\u7684\u5236\u4f5c\u548c\u4f7f\u7528<br \/>\n\u5185\u5b58\u7ba1\u7406<br \/>\n\u6587\u4ef6\u7ba1\u7406\u548c\u6587\u4ef6\u7cfb\u7edf<br \/>\n\u8fdb\u7a0b\u7ba1\u7406<br \/>\n\u4fe1\u53f7<br \/>\n&#xff08;\u8f6f\u4e2d\u65ad&#xff09;<br \/>\n\u8fdb\u7a0b\u95f4\u901a\u8baf<br \/>\n\u7f51\u7edc\u7ba1\u7406<br \/>\n\u7ebf\u7a0b\u7ba1\u7406<\/p>\n<h2>\u516d&#xff0c;\u73af\u5883\u53d8\u91cf<\/h2>\n<h3>\u4ec0\u4e48\u662f\u73af\u5883\u53d8\u91cf&#xff1f;<\/h3>\n<p>\u6bcf\u4e2a\u8fdb\u7a0b\u90fd\u6709\u4e00\u5f20\u81ea\u5df1\u7684\u73af\u5883\u53d8\u91cf\u8868&#xff0c;\u8868\u4e2d\u7684\u6bcf\u4e2a\u6761\u76ee\u90fd\u662f\u5f62\u5982\u201c\u952e&#061;\u503c\u201d\u5f62\u5f0f\u7684\u73af\u5883\u53d8\u91cf\u3002<br \/>\n\u8fdb\u7a0b\u53ef\u4ee5\u901a\u8fc7\u73af\u5883\u53d8\u91cf\u8bbf\u95ee\u8ba1\u7b97\u673a\u7684\u8d44\u6e90<br \/>\n\u5728\u7ec8\u7aef\u4e0b\u8f93\u5165env\u547d\u4ee4&#xff0c;\u53ef\u4ee5\u67e5\u770b\u73af\u5883\u53d8\u91cf\u5217\u8868<\/p>\n<p>\u901a\u8fc7echo $name\u53ef\u4ee5\u67e5\u770b\u67d0\u4e2a\u73af\u5883\u53d8\u91cf\u7684\u503c<\/p>\n<h3>\u73af\u5883\u53d8\u91cf\u7684\u6dfb\u52a0<\/h3>\n<p>\u5728\u7ec8\u7aef\u7a97\u53e3\u8f93\u5165FOOD&#061;guobaorou&#xff0c;\u8868\u793a\u5411\u5f53\u524d\u8fdb\u7a0b\u4e2d\u589e\u52a0\u540d\u4e3a\u201cFOOD\u201d\u503c\u4e3a\u201cguobaorou\u201d\u7684\u73af\u5883\u53d8\u91cf&#xff0c;\u5982\u679c\u73af\u5883\u53d8\u91cf\u5df2\u7ecf\u5b58\u5728&#xff0c;\u5219\u66f4\u6539\u5176\u503c\u3002\u5f3a\u8c03&#xff01;\u5728\u201c\u201d\u5de6\u53f3\u4e0d\u8981\u52a0\u7a7a\u683c<\/p>\n<h3>\u73af\u5883\u53d8\u91cf\u7684\u7c7b\u522b<\/h3>\n<p>\u73af\u5883\u53d8\u91cf\u5206\u6210\u4e24\u5927\u7c7b&#xff1a;<br \/>\n\u5168\u5c40\u73af\u5883\u53d8\u91cf&#xff1a;\u5f53\u524dshell\u548c\u5176\u5b50\u8fdb\u7a0b\u90fd\u662f\u53ef\u89c1\u7684<br \/>\n\u5c40\u90e8\u73af\u5883\u53d8\u91cf&#xff1a;\u53ea\u6709\u5f53\u524dshell\u53ef\u89c1<\/p>\n<p>\u5c06\u5c40\u90e8\u73af\u5883\u53d8\u91cf\u8bbe\u7f6e\u6210\u5168\u5c40\u53d8\u91cf<br \/>\nexport name<\/p>\n<p>\u5220\u9664\u73af\u5883\u53d8\u91cf<br \/>\nunset name<\/p>\n<h3>\u5e38\u89c1\u73af\u5883\u53d8\u91cf<\/h3>\n<p>PATH\u73af\u5883\u53d8\u91cf<br \/>\necho $PATH<br \/>\nPAHT&#061;\/home\/tarena\/Qt5.4.1\/5.4\/gcc_64\/bin:\/home\/tarena\/Qt5.4.1\/Tools\/Qt<br \/>\nCreator\/bin:\/home\/tarena\/bin:\/home\/ta:era\/.local\/bin:\/usr\/local\/sbin:\/usr\/\/lo<br \/>\ncal\/bin:\/usr\/sbin:\/usr\/bin:\/sbin:\/bin:\/:sr\/games:\/usr\/local\/games:\/snap\/bin<\/p>\n<p>\u8be5\u73af\u5883\u53d8\u91cf\u6240\u8bb0\u5f55\u7684\u662fbash\u8fdb\u7a0b\u5bf9\u547d\u4ee4\u7684\u68c0\u7d22\u8def\u5f84\u683c\u5f0f\u4e3a\u201d&#xff1a;\u5206\u5272\u7684\u591a\u4e2a\u8def\u5f84\u3002\u5f53\u5728bash\u4e0b\u8f93\u5165\u547d\u4ee4\u7684\u65f6\u5019&#xff0c;\u9996\u5148&#xff0c;\u5728\u7b2c\u4e00\u4e2a\u8def\u5f84\u4e0b\u627e\u8be5\u547d\u4ee4\u7684\u53ef\u6267\u884c\u7a0b\u5e8f&#xff0c;\u627e\u5230\u5c31\u6267\u884c&#xff0c;\u4e0d\u518d\u5411\u540e\u627e&#xff1b;\u5982\u679c\u627e\u4e0d\u5230&#xff0c;\u5728\u7b2c\u4e8c\u4e2a\u8def\u5f84\u4e0b\u627e&#xff0c;\u627e\u5230\u5c31\u6267\u884c&#xff0c;\u4e0d\u518d\u5411\u540e\u627e&#xff1b;\u5982\u679c\u627e\u4e0d\u5230&#xff0c;\u7ee7\u7eed\u4e0b\u4e00\u4e2a\u8def\u5f84\u3002\u5982\u679c\u5230\u6700\u540e\u4e00\u4e2a\u8def\u5f84\u90fd\u627e\u4e0d\u5230&#xff0c;\u5c31\u63d0\u793a\u8be5\u547d\u4ee4\u4e0d\u80fd\u627e\u5230\u7684\u9519\u8bef\u3002<\/p>\n<p>\u5bf9PAHT\u73af\u5883\u53d8\u91cf\u8fdb\u884c\u8bbe\u7f6e&#xff0c;\u6dfb\u52a0\u5f53\u524d\u8def\u5f84\u5230\u73af\u5883\u53d8\u91cf<br \/>\nPATH&#061;$PATH:<br \/>\n\u5728\u547d\u4ee4\u884c\u6267\u884c\u7a0b\u5e8f\u5373\u53ef\u7701\u7565\u201c\/\u201d\u3002<br \/>\n.\/a.out  \u2014&gt;  a.out<\/p>\n<p>\u5982\u679c\u6ca1\u6709\u7279\u6b8a\u64cd\u4f5c&#xff0c;\u5bf9\u73af\u5883\u53d8\u91cf\u7684\u8bbe\u7f6e\u4ec5\u5bf9\u5f53\u524dshell\u8fdb\u7a0b\u6709\u6548&#xff0c;\u5f00\u542f\u65b0\u7684\u7ec8\u7aef&#xff0c;\u4e4b\u524d\u7684\u64cd\u4f5c\u4e0d\u4f1a\u88ab\u4fdd\u7559\u3002\u5728\u5bb6\u76ee\u5f55\u4e0b\u6709\u540d\u4e3a.bashrc\u7684\u811a\u672c\u6587\u4ef6&#xff0c;\u6bcf\u6b21bash\u8fdb\u7a0b\u542f\u52a8\u524d&#xff0c;\u90fd\u4f1a\u6267\u884c\u8be5\u811a\u672c\u6587\u4ef6\u7684\u5185\u5bb9\u3002\u5982\u679c\u5e0c\u671b\u73af\u5883\u53d8\u91cf\u7684\u8bbe\u7f6e\u5bf9\u6bcf\u4e2abash\u8fdb\u7a0b\u90fd\u6709\u6548&#xff0c;\u53ef\u4ee5\u5c06\u73af\u5883\u53d8\u91cf\u7684\u8bbe\u7f6e\u5199\u5728\u8be5\u811a\u672c\u6587\u4ef6\u4e2d\u3002<br \/>\n\u6267\u884csource~\/.bashrc\u547d\u4ee4&#xff0c;\u53ef\u4ee5\u4f7f\u6587\u4ef6\u7acb\u5373\u751f\u6548\u3002<\/p>\n<h2>\u4e03\u3001\u73af\u5883\u53d8\u91cf\u8868<\/h2>\n<p>main\u51fd\u6570\u7684\u7b2c\u4e09\u4e2a\u53c2\u6570<br \/>\nmain\u51fd\u6570\u7684\u7b2c\u4e09\u4e2a\u53c2\u6570\u5c31\u662f\u73af\u5883\u53d8\u91cf\u8868\u7684\u8d77\u59cb\u5730\u5740<\/p>\n<p><span class=\"token keyword\">int<\/span> <span class=\"token function\">main<\/span> <span class=\"token punctuation\">(<\/span><span class=\"token keyword\">int<\/span> argc<span class=\"token punctuation\">,<\/span> <span class=\"token keyword\">char<\/span><span class=\"token operator\">*<\/span> argv<span class=\"token punctuation\">[<\/span><span class=\"token punctuation\">]<\/span><span class=\"token punctuation\">,<\/span> <span class=\"token keyword\">char<\/span><span class=\"token operator\">*<\/span> envp<span class=\"token punctuation\">[<\/span><span class=\"token punctuation\">]<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<\/span><br \/>\n<span class=\"token keyword\">extern<\/span> <span class=\"token keyword\">char<\/span><span class=\"token operator\">*<\/span><span class=\"token operator\">*<\/span> environ<span class=\"token punctuation\">;<\/span><br \/>\n<span class=\"token function\">printf<\/span> <span class=\"token punctuation\">(<\/span><span class=\"token string\">&#034;%p,%p\\\\n&#034;<\/span><span class=\"token punctuation\">,<\/span> environ<span class=\"token punctuation\">,<\/span> envp<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><span class=\"token comment\">\/\/\u76f8\u7b49<\/span><br \/>\n<span class=\"token keyword\">char<\/span> <span class=\"token operator\">*<\/span><span class=\"token operator\">*<\/span>pp<span class=\"token punctuation\">;<\/span><br \/>\n<span class=\"token keyword\">for<\/span> <span class=\"token punctuation\">(<\/span>pp <span class=\"token operator\">&#061;<\/span>envp<span class=\"token punctuation\">;<\/span> <span class=\"token operator\">*<\/span>pp<span class=\"token punctuation\">;<\/span> <span class=\"token operator\">&#043;&#043;<\/span>pp<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">{<\/span><br \/>\n<span class=\"token function\">printf<\/span> <span class=\"token punctuation\">(<\/span><span class=\"token string\">&#034;%s(n&#034;<\/span><span class=\"token punctuation\">,<\/span> <span class=\"token operator\">*<\/span>pp<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n<span class=\"token punctuation\">}<\/span><br \/>\n<span class=\"token keyword\">return<\/span> <span class=\"token number\">0<\/span><span class=\"token punctuation\">;<\/span><br \/>\n<span class=\"token punctuation\">}<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4e00&#xff0c;\u4ec0\u4e48\u662fUC&#xff1f;<br \/>\nU\u662f\u6307unix\u64cd\u4f5c\u7cfb\u7edf\u3002Unix\u64cd\u4f5c\u7cfb\u7edf\u662f\u4f7f\u7528C\u8bed\u8a00\u5b9e\u73b0\u7684\u7cfb\u7edf\u7ea7\u8f6f\u4ef6\u3002<br \/>\nC\u662f\u6307C\u8bed\u8a00&#xff0c;\u5c31\u662f\u5927\u5bb6\u4e0a\u95e8\u8bfe\u7a0b\u5b66\u4e60\u7684\u8bed\u8a00\u3002<br \/>\nUC\u662f\u6307\u4f7f\u7528C\u8bed\u8a00\u5728\u64cd\u4f5c\u7cfb\u7edfUnix\u4e0a\u7684\u7528\u6237\u7f16\u7a0b\u3002unix\u7cfb\u7edf\u5411\u7528\u6237\u63d0\u4f9b\u4e86\u5927<br \/>\n\u91cf\u7684\u63a5\u53e3\u3002\u7528\u6237\u901a\u8fc7\u7cfb\u7edf\u63d0\u4f9b\u7684\u63a5&#xff0c;\u4f7f\u7528\u64cd\u4f5c\u7cfb\u7edf\u63d0\u4f9b\u7684\u670d\u52a1\u3002<br \/>\n\u60f3\u8981\u5199\u51fa\u529f\u80fd\u5f3a\u5927\u7684\u7a0b\u5e8f&#xff0c;\u4e00\u5b9a\u8981\u501f\u52a9\u64cd\u4f5c\u7cfb\u7edf\u63d0\u4f9b\u7684\u529f\u80fd\u3002<br \/>\n\u6bd4\u5982&#xff1a;\u7f51\u7edc\u901a\u4fe1&#xff0c;\u8fdb\u7a0b\u7ba1\u7406&#xff0c;\u7ebf\u7a0b\u7ba1\u7406\u7b49\u3002<br \/>\n\u4e8c<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[305],"topic":[],"class_list":["post-114298","post","type-post","status-publish","format-standard","hentry","category-server","tag-305"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>p1-\u4ec0\u4e48\u662fUC\uff1f\u64cd\u4f5c\u7cfb\u7edf\u7684\u5386\u53f2 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/114298.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"p1-\u4ec0\u4e48\u662fUC\uff1f\u64cd\u4f5c\u7cfb\u7edf\u7684\u5386\u53f2 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u4e00&#xff0c;\u4ec0\u4e48\u662fUC&#xff1f; U\u662f\u6307unix\u64cd\u4f5c\u7cfb\u7edf\u3002Unix\u64cd\u4f5c\u7cfb\u7edf\u662f\u4f7f\u7528C\u8bed\u8a00\u5b9e\u73b0\u7684\u7cfb\u7edf\u7ea7\u8f6f\u4ef6\u3002 C\u662f\u6307C\u8bed\u8a00&#xff0c;\u5c31\u662f\u5927\u5bb6\u4e0a\u95e8\u8bfe\u7a0b\u5b66\u4e60\u7684\u8bed\u8a00\u3002 UC\u662f\u6307\u4f7f\u7528C\u8bed\u8a00\u5728\u64cd\u4f5c\u7cfb\u7edfUnix\u4e0a\u7684\u7528\u6237\u7f16\u7a0b\u3002unix\u7cfb\u7edf\u5411\u7528\u6237\u63d0\u4f9b\u4e86\u5927 \u91cf\u7684\u63a5\u53e3\u3002\u7528\u6237\u901a\u8fc7\u7cfb\u7edf\u63d0\u4f9b\u7684\u63a5&#xff0c;\u4f7f\u7528\u64cd\u4f5c\u7cfb\u7edf\u63d0\u4f9b\u7684\u670d\u52a1\u3002 \u60f3\u8981\u5199\u51fa\u529f\u80fd\u5f3a\u5927\u7684\u7a0b\u5e8f&#xff0c;\u4e00\u5b9a\u8981\u501f\u52a9\u64cd\u4f5c\u7cfb\u7edf\u63d0\u4f9b\u7684\u529f\u80fd\u3002 \u6bd4\u5982&#xff1a;\u7f51\u7edc\u901a\u4fe1&#xff0c;\u8fdb\u7a0b\u7ba1\u7406&#xff0c;\u7ebf\u7a0b\u7ba1\u7406\u7b49\u3002 \u4e8c\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/114298.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-10-08T14:32:45+00:00\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/114298.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/114298.html\",\"name\":\"p1-\u4ec0\u4e48\u662fUC\uff1f\u64cd\u4f5c\u7cfb\u7edf\u7684\u5386\u53f2 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-10-08T14:32:45+00:00\",\"dateModified\":\"2026-10-08T14:32:45+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/114298.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/114298.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/114298.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"p1-\u4ec0\u4e48\u662fUC\uff1f\u64cd\u4f5c\u7cfb\u7edf\u7684\u5386\u53f2\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"p1-\u4ec0\u4e48\u662fUC\uff1f\u64cd\u4f5c\u7cfb\u7edf\u7684\u5386\u53f2 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/114298.html","og_locale":"zh_CN","og_type":"article","og_title":"p1-\u4ec0\u4e48\u662fUC\uff1f\u64cd\u4f5c\u7cfb\u7edf\u7684\u5386\u53f2 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u4e00&#xff0c;\u4ec0\u4e48\u662fUC&#xff1f; U\u662f\u6307unix\u64cd\u4f5c\u7cfb\u7edf\u3002Unix\u64cd\u4f5c\u7cfb\u7edf\u662f\u4f7f\u7528C\u8bed\u8a00\u5b9e\u73b0\u7684\u7cfb\u7edf\u7ea7\u8f6f\u4ef6\u3002 C\u662f\u6307C\u8bed\u8a00&#xff0c;\u5c31\u662f\u5927\u5bb6\u4e0a\u95e8\u8bfe\u7a0b\u5b66\u4e60\u7684\u8bed\u8a00\u3002 UC\u662f\u6307\u4f7f\u7528C\u8bed\u8a00\u5728\u64cd\u4f5c\u7cfb\u7edfUnix\u4e0a\u7684\u7528\u6237\u7f16\u7a0b\u3002unix\u7cfb\u7edf\u5411\u7528\u6237\u63d0\u4f9b\u4e86\u5927 \u91cf\u7684\u63a5\u53e3\u3002\u7528\u6237\u901a\u8fc7\u7cfb\u7edf\u63d0\u4f9b\u7684\u63a5&#xff0c;\u4f7f\u7528\u64cd\u4f5c\u7cfb\u7edf\u63d0\u4f9b\u7684\u670d\u52a1\u3002 \u60f3\u8981\u5199\u51fa\u529f\u80fd\u5f3a\u5927\u7684\u7a0b\u5e8f&#xff0c;\u4e00\u5b9a\u8981\u501f\u52a9\u64cd\u4f5c\u7cfb\u7edf\u63d0\u4f9b\u7684\u529f\u80fd\u3002 \u6bd4\u5982&#xff1a;\u7f51\u7edc\u901a\u4fe1&#xff0c;\u8fdb\u7a0b\u7ba1\u7406&#xff0c;\u7ebf\u7a0b\u7ba1\u7406\u7b49\u3002 \u4e8c","og_url":"https:\/\/www.wsisp.com\/helps\/114298.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-10-08T14:32:45+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"2 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/114298.html","url":"https:\/\/www.wsisp.com\/helps\/114298.html","name":"p1-\u4ec0\u4e48\u662fUC\uff1f\u64cd\u4f5c\u7cfb\u7edf\u7684\u5386\u53f2 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-10-08T14:32:45+00:00","dateModified":"2026-10-08T14:32:45+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/114298.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/114298.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/114298.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"p1-\u4ec0\u4e48\u662fUC\uff1f\u64cd\u4f5c\u7cfb\u7edf\u7684\u5386\u53f2"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/114298","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=114298"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/114298\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=114298"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=114298"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=114298"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=114298"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}