{"id":3832,"date":"2023-10-31T18:34:50","date_gmt":"2023-10-31T10:34:50","guid":{"rendered":"https:\/\/white-night.club\/?p=3832"},"modified":"2024-01-29T17:05:48","modified_gmt":"2024-01-29T09:05:48","slug":"pg18","status":"publish","type":"post","link":"https:\/\/white-night.club\/index.php\/2023\/10\/31\/pg18\/","title":{"rendered":"C#\uff1a\u8fd0\u7b97\u7b26\u5728\u503c\u7684\u524d\u540e\u533a\u522b"},"content":{"rendered":"\n<p>value++\u548c++value\u7406\u89e3\u8d77\u6765\u5176\u5b9e\u4e0d\u96be\uff0c\u591a\u7528\u51e0\u6b21\u5c31\u7406\u89e3\u4e86\u3002\u4e3b\u8981\u662fMicrosoft\u57f9\u8bad\u6587\u6863\u90a3\u4e2a\u4e2d\u6587\u6559\u7a0b\uff0c\u592a\u96be\u8bfb\u61c2\u4e86\uff0c\u8ddf\u673a\u7ffb\u4e00\u6837\u3002\u6240\u4ee5\u5f00\u7bc7\u6587\u7ae0\uff0c\u7528\u7b80\u5355\u51e0\u53e5\u8bdd\u89e3\u91ca\u4e0b\u8fd0\u7b97\u7b26\u5728\u503c\u524d\u540e\u7684\u533a\u522b\u3002<\/p>\n\n\n\n<div style=\"height:60px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<blockquote class=\"wp-block-quote has-luminous-vivid-amber-color has-text-color\">\n<p>\u5177\u4f53\u4f8b\u5b50<\/p>\n<cite><em>\u5148\u8fd0\u7b97\u8fd8\u662f\u540e\u8fd0\u7b97<\/em><\/cite><\/blockquote>\n\n\n\n<p>\u5148++\u8fd8\u662f\u540e++\uff0c\u5176\u5b9e\u548c\u6211\u4eec\u5e73\u5e38\u751f\u6d3b\u4e2d\u7684\u7406\u89e3\u5dee\u4e0d\u591a\uff0c\u7f16\u8bd1\u5668\u4e5f\u662f\u4ece\u5de6\u5230\u53f3\u8bfb\u53d6\u4f60\u7684\u4ee3\u7801\u3002<\/p>\n\n\n\n<p>\u6bd4\u5982\u4e0b\u9762\u8fd9\u6bb5\u4ee3\u7801<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>int num=1;\r\nConsole.WriteLine($\"num is:{num++}\");\r\nConsole.WriteLine($\"nums is:{++num}\");\r<\/code><\/pre>\n\n\n\n<p>\u5b83\u8fd0\u884c\u4e4b\u540e\u5f97\u5230\u7684\u8f93\u51fa\u662f<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>num is:1\r\nnums is:3<\/code><\/pre>\n\n\n\n<p>\u4e0d\u96be\u7406\u89e3\u3002\u5bf9\u4e8enum++\u800c\u8a00\uff0c\u5148\u6267\u884c\u7684\u662f<mark style=\"background-color:rgba(0, 0, 0, 0);color:#fcb900\" class=\"has-inline-color\">\u201c\u8bfb\u53d6num\u201d<\/mark>\u7684\u64cd\u4f5c\uff0c\u5f53WriteLine\u8bfb\u53d6\u5b8cnum\u503c\u4e4b\u540e\u518d\u6267\u884c\u7684<mark style=\"background-color:rgba(0, 0, 0, 0);color:#fcb900\" class=\"has-inline-color\">\u201cnum +1\u201d<\/mark>\u64cd\u4f5c\u3002<\/p>\n\n\n\n<p>\u800c++num\u5219\u662f\u5148\u6267\u884c\u7684<mark style=\"background-color:rgba(0, 0, 0, 0);color:#fcb900\" class=\"has-inline-color\">\u201cnum+1\u201d<\/mark>\u64cd\u4f5c\uff0c\u518d\u6267\u884c\u7684<mark style=\"background-color:rgba(0, 0, 0, 0);color:#fcb900\" class=\"has-inline-color\">\u201c\u8bfb\u53d6num\u201d<\/mark>\u64cd\u4f5c\u3002<\/p>\n\n\n\n<p>&#8211;num\u548cnum&#8211;\u540c\u7406\uff0c\u4e0d\u96be\u7406\u89e3\u3002\u5c31\u662f\u53ef\u80fd\u6709\u65f6\u5019\u4f1a\u6709\u90a3\u4e48\u4e00\u70b9\u70b9\u7ed5\uff08\u6bd4\u5982\u5728C\u7684for\u5faa\u73af\u91cc\uff09\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>value++\u548c++value<\/p>\n","protected":false},"author":1,"featured_media":3838,"comment_status":"open","ping_status":"","sticky":false,"template":"base","format":"standard","meta":{"footnotes":""},"categories":[97,33],"tags":[137],"_links":{"self":[{"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/posts\/3832"}],"collection":[{"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/comments?post=3832"}],"version-history":[{"count":0,"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/posts\/3832\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/media\/3838"}],"wp:attachment":[{"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/media?parent=3832"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/categories?post=3832"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/white-night.club\/index.php\/wp-json\/wp\/v2\/tags?post=3832"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}