{"id":15517,"date":"2024-11-18T20:01:22","date_gmt":"2024-11-18T12:01:22","guid":{"rendered":"https:\/\/fwq.ai\/blog\/?p=15517"},"modified":"2024-11-18T20:01:22","modified_gmt":"2024-11-18T12:01:22","slug":"go%e4%b8%ad%e7%9a%84%e5%90%84%e7%a7%8d%e5%8f%98%e9%87%8f%e7%b1%bb%e5%9e%8b%e8%bd%ac%e6%8d%a2","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/15517\/","title":{"rendered":"Go\u4e2d\u7684\u5404\u79cd\u53d8\u91cf\u7c7b\u578b\u8f6c\u6362"},"content":{"rendered":"<p>\u4ecePHP\u8f6c\u5411GO\uff0c\u6700\u4e0d\u80fd\u9002\u5e94\u7684\u662fGO\u662f\u5f3a\u7c7b\u578b\u8bed\u8a00\uff0c\u53d8\u91cf\u7684\u7533\u660e\u9700\u8981\u6307\u5b9a\u5176\u7c7b\u578b\uff0c\u76f8\u540c\u7684\u53d8\u91cf\u4e4b\u95f4\u624d\u53ef\u4ee5\u505a\u7b97\u672f\u3001\u5173\u7cfb\u3001\u903b\u8f91\u7b49\u8fd0\u7b97\u3002<\/p>\n<p>&nbsp;<\/p>\n<p>Go\u4e2d\u6240\u6709\u7684\u53d8\u91cf\u7c7b\u578b\u53c2\u8003\uff1aGo\u65b0\u624b\u9700\u6ce8\u610f\u7684\u77e5\u8bc6\u70b9(\u4e00)<\/p>\n<h3><strong>\u00a0\u4e00\u3001string\u7c7b\u578b<\/strong><\/h3>\n<table border=\"1\" cellpadding=\"5\">\n<tbody>\n<tr>\n<td valign=\"top\" width=\"20%\">int<br \/>\nint8<br \/>\nint16<br \/>\nint32<br \/>\nint64<\/td>\n<td valign=\"top\">\u00a0string\u8f6c\u6362\u6210\u8fd95\u79cd\u7c7b\u578b\uff0c\u9700\u8981\u5148\u4f7f\u7528\u00a0<strong>strconv.ParseInt(s,10,64)<\/strong>, \u8f6c\u6362\u6210\u76f8\u5bf9\u5e94\u7684int64\uff0c\u7136\u540e\u4f7f\u7528\u5f3a\u5236\u8f6c\u6362\u3002\u4f8b\u5982\uff1a<br \/>\nr,_ := strconv.Parseint(\u201c123\u2033,10,8)<br \/>\nint8(r)<strong>func ParseInt(s string, base int, bitSize int) (i int64, err error)<\/strong><br \/>\n\u8fd4\u56de\u5b57\u7b26\u4e32\u8868\u793a\u7684\u6574\u6570\u503c\uff0c\u63a5\u53d7\u6b63\u8d1f\u53f7\u3002<br \/>\nbase\u6307\u5b9a\u8fdb\u5236\uff082\u523036\uff09\uff0c\u5982\u679cbase\u4e3a0\uff0c\u5219\u4f1a\u4ece\u5b57\u7b26\u4e32\u524d\u7f6e\u5224\u65ad\uff0c\u201d0x\u201d\u662f16\u8fdb\u5236\uff0c\u201d0\u2033\u662f8\u8fdb\u5236\uff0c\u5426\u5219\u662f10\u8fdb\u5236\uff1b<br \/>\nbitSize\u6307\u5b9a\u7ed3\u679c\u5fc5\u987b\u80fd\u65e0\u6ea2\u51fa\u8d4b\u503c\u7684\u6574\u6570\u7c7b\u578b\uff0c0\u30018\u300116\u300132\u300164 \u5206\u522b\u4ee3\u8868 int\u3001int8\u3001int16\u3001int32\u3001int64\uff1b\u8fd4\u56de\u7684err\u662f*NumErr\u7c7b\u578b\u7684\uff0c\u5982\u679c\u8bed\u6cd5\u6709\u8bef\uff0cerr.Error = ErrSyntax\uff1b\u5982\u679c\u7ed3\u679c\u8d85\u51fa\u7c7b\u578b\u8303\u56f4err.Error = ErrRange\u3002\u4ece\u4e0a\u9762\u7684\u63cf\u8ff0\u4e2d\uff0c\u4e5f\u53ef\u4ee5\u5f97\u77e5\uff0c\u8be5\u65b9\u6cd5\u8fd8\u53ef\u4ee5\u7528\u4e8e\u8f6c\u63622\u8fdb\u5236\u30018\u8fdb\u5236\u300116\u8fdb\u5236\u523010\u8fdb\u5236\uff0c\u4f8b\u5982\uff1a<br \/>\nstrconv.ParseInt(\u201c1110110\u2033,2,64),\u8fd4\u56de\u7ed3\u679c\uff1a118<strong>\u7279\u6b8a\u7684\u65b9\u6cd5\uff1a<br \/>\nfunc Atoi(s string) (i int, err error)<br \/>\n<\/strong>Atoi\u662fParseInt(s, 10, 0)\u7684\u7b80\u5199\u3002<strong><br \/>\n<\/strong><\/td>\n<\/tr>\n<tr>\n<td valign=\"top\">uint<br \/>\nuint8<br \/>\nuint16<br \/>\nuint32<br \/>\nuint64<\/td>\n<td valign=\"top\">\u540c\u4e0a\uff0cParseUint\u7c7b\u4f3cParseInt\u4f46\u4e0d\u63a5\u53d7\u6b63\u8d1f\u53f7\uff0c\u7528\u4e8e\u65e0\u7b26\u53f7\u6574\u578b<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\">float32<br \/>\nfloat64<\/td>\n<td valign=\"top\">\u7528\u6cd5\u540c\u4e0a\uff0c\u5148\u4f7f\u7528<strong>\u00a0strconv.ParseFloat(s,64)\uff0c<\/strong>\u7136\u540e\u5f3a\u5236\u8f6c\u6362\u6210\u76f8\u5bf9\u5e94\u7684\u7c7b\u578b\u3002<strong>func ParseFloat(s string, bitSize int) (f float64, err error)<\/strong><br \/>\n\u89e3\u6790\u4e00\u4e2a\u8868\u793a\u6d6e\u70b9\u6570\u7684\u5b57\u7b26\u4e32\u5e76\u8fd4\u56de\u5176\u503c\u3002<br \/>\n\u5982\u679cs\u5408\u4e4e\u8bed\u6cd5\u89c4\u5219\uff0c\u51fd\u6570\u4f1a\u8fd4\u56de\u6700\u4e3a\u63a5\u8fd1s\u8868\u793a\u503c\u7684\u4e00\u4e2a\u6d6e\u70b9\u6570\uff08\u4f7f\u7528IEEE754\u89c4\u8303\u820d\u5165\uff09\u3002bitSize\u6307\u5b9a\u4e86\u671f\u671b\u7684\u63a5\u6536\u7c7b\u578b\uff0c32\u662ffloat32\uff08\u8fd4\u56de\u503c\u53ef\u4ee5\u4e0d\u6539\u53d8\u7cbe\u786e\u503c\u7684\u8d4b\u503c\u7ed9float32\uff09\uff0c64\u662ffloat64\uff1b\u8fd4\u56de\u503cerr\u662f*NumErr\u7c7b\u578b\u7684\uff0c\u8bed\u6cd5\u6709\u8bef\u7684\uff0cerr.Error=ErrSyntax\uff1b\u7ed3\u679c\u8d85\u51fa\u8868\u793a\u8303\u56f4\u7684\uff0c\u8fd4\u56de\u503cf\u4e3a\u00b1Inf\uff0cerr.Error= ErrRange\u3002<strong>\u6ce8\u610f\uff1a\u4f7f\u7528float\u7c7b\u578b\u4e00\u5b9a\u8981\u6ce8\u610f\u5176\u7cbe\u5ea6<\/strong><\/td>\n<\/tr>\n<tr>\n<td valign=\"top\">[]byte<\/td>\n<td valign=\"top\"><strong>[]byte(s)<\/strong>\u00a0\uff0c\u800c\u4ece\u5b57\u8282\u5207\u7247\u8f6c\u6362\u6210string\uff0c\u5219\u4f7f\u7528\u00a0<strong>string(b)\uff0c<\/strong>\u4ece\u8fd9\u91cc\u53ef\u4ee5\u770b\u51fa[]byte\u548cstring\u53ef\u4ee5\u4f7f\u7528\u5f3a\u5236\u8f6c\u6362\u3002<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\">rune<\/td>\n<td valign=\"top\">\u540c\u4e0a\uff0c\u5148\u4f7f\u7528\u00a0strconv.ParseInt(s,10,64)\uff0c\u8f6c\u6362\u6210int64\uff0c\u7136\u540e\u4f7f\u7528\u5f3a\u5236\u8f6c\u6362<br \/>\nr ,_ := strconv.ParseInt(s,10,64)<br \/>\nrune(r)<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\">bool<\/td>\n<td valign=\"top\"><strong>bool, err := strconv.ParseBool(s)<\/strong><br \/>\n\u8fd4\u56de\u5b57\u7b26\u4e32\u8868\u793a\u7684bool\u503c\u3002\u5b83\u63a5\u53d71\u30010\u3001t\u3001f\u3001T\u3001F\u3001true\u3001false\u3001True\u3001False\u3001TRUE\u3001FALSE\uff1b\u5426\u5219\u8fd4\u56de\u9519\u8bef\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>\u4e8c\u3001bool\u7c7b\u578b<\/h3>\n<table border=\"1\" cellpadding=\"5\">\n<tbody>\n<tr>\n<td valign=\"top\" width=\"20%\">string<\/td>\n<td valign=\"top\">r := strconv.FormatBool(s)<br \/>\n<strong>func FormatBool(b bool) string<\/strong><br \/>\n\u6839\u636eb\u7684\u503c\u8fd4\u56de\u201dtrue\u201d\u6216\u201dfalse\u201d\u3002<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"20%\">\u5176\u4ed6\u7c7b\u578b<\/td>\n<td valign=\"top\">\u4e00\u822c\u60c5\u51b5\u5f88\u5c11\u5c06bool\u8f6c\u6362\u6210\u5b57\u7b26\u4ee5\u5916\u7684\u7c7b\u578b\uff0c\u5982\u679c\u6709\u53ef\u5c06bool\u7c7b\u578b\u8f6c\u6362\u6210string\u540e\uff0c\u518d\u8fdb\u884c\u8f6c\u6362\uff0c\u6216\u8005\u91c7\u7528switch\u7684\u5224\u65ad\u903b\u8f91\uff0c\u53cd\u6b63bool\u5c312\u79cd\u503c\u7c7b\u578b\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>\u4e09\u3001int\u3001int8\u3001int16\u3001int32\u3001int64\u7c7b\u578b<\/h3>\n<table border=\"1\" cellpadding=\"5\">\n<tbody>\n<tr>\n<td valign=\"top\" width=\"20%\">string<\/td>\n<td valign=\"top\">\u5c06\u8fd95\u79cd\u7c7b\u578b\u8f6c\u6362\u5230string\u7c7b\u578b\uff0c\u9700\u8981\u5148\u4f7f\u7528\u5f3a\u5236\u8f6c\u6362\u5230int64\uff0c\u518d\u4f7f\u7528<strong>strconv.FormatInt(int64(s),10)<\/strong>&nbsp;<\/p>\n<p><strong>func FormatInt(i int64, base int) string<\/strong><br \/>\n\u8fd4\u56dei\u7684base\u8fdb\u5236\u7684\u5b57\u7b26\u4e32\u8868\u793a\u3002base \u5fc5\u987b\u57282\u523036\u4e4b\u95f4\uff0c\u7ed3\u679c\u4e2d\u4f1a\u4f7f\u7528\u5c0f\u5199\u5b57\u6bcd\u2019a\u2019\u5230\u2019z\u2019\u8868\u793a\u5927\u4e8e10\u7684\u6570\u5b57\u3002<\/p>\n<p>\u540c\u7406\uff1a\u8be5\u65b9\u6cd5\u4e5f\u53ef\u4ee5\u5c06\u8fd95\u79cd\u7c7b\u578b\uff0c\u8f6c\u6362\u62102\u8fdb\u5236\uff0c8\u8fdb\u5236\uff0c10\u8fdb\u5236\u7684\u5b57\u7b26\u4e32\u3002<br \/>\nvar s = 35<br \/>\nr := strconv.FormatInt(int64(s),2)<br \/>\nfmt.Println(r) \u00a0\/\/\u00a0100011<\/p>\n<p>\u7279\u6b8a\u65b9\u6cd5\uff1a<br \/>\n<strong>func Itoa(i int) string<\/strong><br \/>\nItoa\u662fFormatInt(i, 10) \u7684\u7b80\u5199\u3002<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"20%\">uint<br \/>\nuint8<br \/>\nuint16<br \/>\nuint32<br \/>\nuint64<br \/>\nfloat32<br \/>\nfloat64<\/td>\n<td valign=\"top\">\u4f7f\u7528\u5f3a\u5236\u8f6c\u6362\u3002<br \/>\nvar s = 35<br \/>\nuint(s)<br \/>\nuint8(s)<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"20%\">\u5176\u4ed6\u7c7b\u578b<\/td>\n<td valign=\"top\">\u53ef\u8f6c\u6362\u5230string\u540e\uff0c\u518d\u8fdb\u884c\u8f6c\u6362<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><strong>\u56db\u3001uint\u3001uint8\u3001uint16\u3001uint32\u3001uint64\u7c7b\u578b<\/strong><\/p>\n<table border=\"1\" cellpadding=\"5\">\n<tbody>\n<tr>\n<td valign=\"top\" width=\"20%\">string<\/td>\n<td valign=\"top\">\u5c06\u8fd95\u79cd\u7c7b\u578b\u8f6c\u6362\u5230string\u7c7b\u578b\uff0c\u9700\u8981\u5148\u4f7f\u7528\u5f3a\u5236\u8f6c\u6362\u5230uint64\uff0c\u518d\u4f7f\u7528<strong>strconv.FormatUint(uint64(s),10)<\/strong>&nbsp;<\/p>\n<p>func FormatUint(i uint64, base int) string<br \/>\n\u662fFormatInt\u7684\u65e0\u7b26\u53f7\u6574\u6570\u7248\u672c\u3002<\/p>\n<p>\u540c\u7406\uff1a\u8be5\u65b9\u6cd5\u4e5f\u53ef\u4ee5\u5c06\u8fd95\u79cd\u7c7b\u578b\uff0c\u8f6c\u6362\u62102\u8fdb\u5236\uff0c8\u8fdb\u5236\uff0c10\u8fdb\u5236\u7684\u5b57\u7b26\u4e32\u3002<br \/>\nvar s = 111<br \/>\nr := strconv.FormatUint(uint64(s),2)<br \/>\nfmt.Println(r) \/\/\u00a01101111<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"20%\">int<br \/>\nint8<br \/>\nint16<br \/>\nint32<br \/>\nint64<br \/>\nfloat32<br \/>\nfloat64<\/td>\n<td valign=\"top\">\u4f7f\u7528\u5f3a\u5236\u8f6c\u6362\u3002<br \/>\nvar s = 35<br \/>\nint(s)<br \/>\nint8(s)<br \/>\nfloat64(s)<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"20%\">\u5176\u4ed6\u7c7b\u578b<\/td>\n<td valign=\"top\">\u53ef\u8f6c\u6362\u5230string\u540e\uff0c\u518d\u8fdb\u884c\u8f6c\u6362<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><strong>\u4e94\u3001float32\u3001float64\u7c7b\u578b<\/strong><\/p>\n<table border=\"1\" cellpadding=\"5\">\n<tbody>\n<tr>\n<td valign=\"top\" width=\"20%\">string<\/td>\n<td valign=\"top\">var s = 111.123456<br \/>\nr := strconv.FormatFloat(float64(s),\u2019f\u2019,3,32)<strong>func FormatFloat(f float64, fmt byte, prec, bitSize int) string<\/strong><br \/>\n\u51fd\u6570\u5c06\u6d6e\u70b9\u6570\u8868\u793a\u4e3a\u5b57\u7b26\u4e32\u5e76\u8fd4\u56de\u3002<br \/>\nbitSize\u8868\u793af\u7684\u6765\u6e90\u7c7b\u578b\uff0832\uff1afloat32\u300164\uff1afloat64\uff09\uff0c\u4f1a\u636e\u6b64\u8fdb\u884c\u820d\u5165\u3002<br \/>\nfmt\u8868\u793a\u683c\u5f0f\uff1a\u2019f\u2019\uff08-ddd.dddd\uff09\u3001\u2019b\u2019\uff08-ddddp\u00b1ddd\uff0c\u6307\u6570\u4e3a\u4e8c\u8fdb\u5236\uff09\u3001\u2019e\u2019\uff08-d.dddde\u00b1dd\uff0c\u5341\u8fdb\u5236\u6307\u6570\uff09\u3001\u2019E\u2019\uff08-d.ddddE\u00b1dd\uff0c\u5341\u8fdb\u5236\u6307\u6570\uff09\u3001\u2019g\u2019\uff08\u6307\u6570\u5f88\u5927\u65f6\u7528\u2019e\u2019\u683c\u5f0f\uff0c\u5426\u5219\u2019f\u2019\u683c\u5f0f\uff09\u3001\u2019G\u2019\uff08\u6307\u6570\u5f88\u5927\u65f6\u7528\u2019E\u2019\u683c\u5f0f\uff0c\u5426\u5219\u2019f\u2019\u683c\u5f0f\uff09\u3002<br \/>\nprec\u63a7\u5236\u7cbe\u5ea6\uff08\u6392\u9664\u6307\u6570\u90e8\u5206\uff09\uff1a\u5bf9\u2019f\u2019\u3001\u2019e\u2019\u3001\u2019E\u2019\uff0c\u5b83\u8868\u793a\u5c0f\u6570\u70b9\u540e\u7684\u6570\u5b57\u4e2a\u6570\uff1b\u5bf9\u2019g\u2019\u3001\u2019G\u2019\uff0c\u5b83\u63a7\u5236\u603b\u7684\u6570\u5b57\u4e2a\u6570\u3002\u5982\u679cprec \u4e3a-1\uff0c\u5219\u4ee3\u8868\u4f7f\u7528\u6700\u5c11\u6570\u91cf\u7684\u3001\u4f46\u53c8\u5fc5\u9700\u7684\u6570\u5b57\u6765\u8868\u793af\u3002<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"20%\">int<br \/>\nint8<br \/>\nint16<br \/>\nint32<br \/>\nint64<br \/>\nuint<br \/>\nuint8<br \/>\nuint16<br \/>\nuint32<br \/>\nuint64<\/td>\n<td valign=\"top\">\u4f7f\u7528\u5f3a\u5236\u8f6c\u6362\u3002<br \/>\nvar s = 35<br \/>\nint(s)<br \/>\nint8(s)<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" width=\"20%\">\u5176\u4ed6\u7c7b\u578b<\/td>\n<td valign=\"top\">\u53ef\u8f6c\u6362\u5230string\u540e\uff0c\u518d\u8fdb\u884c\u8f6c\u6362<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n","protected":false},"excerpt":{"rendered":"<p>\u4ecePHP\u8f6c\u5411GO\uff0c\u6700\u4e0d\u80fd\u9002\u5e94\u7684\u662fGO\u662f\u5f3a\u7c7b\u578b\u8bed\u8a00\uff0c\u53d8\u91cf\u7684\u7533\u660e\u9700\u8981\u6307\u5b9a\u5176\u7c7b\u578b\uff0c\u76f8\u540c\u7684\u53d8\u91cf\u4e4b\u95f4\u624d\u53ef\u4ee5\u505a\u7b97\u672f\u3001\u5173\u7cfb\u3001\u903b\u8f91\u7b49\u8fd0\u7b97\u3002 &nbsp; Go\u4e2d\u6240\u6709\u7684\u53d8\u91cf\u7c7b\u578b\u53c2\u8003\uff1aGo\u65b0\u624b\u9700\u6ce8\u610f\u7684\u77e5\u8bc6\u70b9(\u4e00) \u00a0\u4e00\u3001string\u7c7b\u578b int int8 int16 int32 int64 \u00a0string\u8f6c\u6362\u6210\u8fd95\u79cd\u7c7b\u578b\uff0c\u9700\u8981\u5148\u4f7f\u7528\u00a0strconv.ParseInt(s,10,64), \u8f6c\u6362\u6210\u76f8\u5bf9\u5e94\u7684int64\uff0c\u7136\u540e\u4f7f\u7528\u5f3a\u5236\u8f6c\u6362\u3002\u4f8b\u5982\uff1a r,_ := strconv.Parseint(\u201c123\u2033,10,8) int8(r)func ParseInt(s string, base int, bitSize int) (i int64, err error) \u8fd4\u56de\u5b57\u7b26\u4e32\u8868\u793a\u7684\u6574\u6570\u503c\uff0c\u63a5\u53d7\u6b63\u8d1f\u53f7\u3002 base\u6307\u5b9a\u8fdb\u5236\uff082\u523036\uff09\uff0c\u5982\u679cbase\u4e3a0\uff0c\u5219\u4f1a\u4ece\u5b57\u7b26\u4e32\u524d\u7f6e\u5224\u65ad\uff0c\u201d0x\u201d\u662f16\u8fdb\u5236\uff0c\u201d0\u2033\u662f8\u8fdb\u5236\uff0c\u5426\u5219\u662f10\u8fdb\u5236\uff1b bitSize\u6307\u5b9a\u7ed3\u679c\u5fc5\u987b\u80fd\u65e0\u6ea2\u51fa\u8d4b\u503c\u7684\u6574\u6570\u7c7b\u578b\uff0c0\u30018\u300116\u300132\u300164 \u5206\u522b\u4ee3\u8868 int\u3001int8\u3001int16\u3001int32\u3001int64\uff1b\u8fd4\u56de\u7684err\u662f*NumErr\u7c7b\u578b\u7684\uff0c\u5982\u679c\u8bed\u6cd5\u6709\u8bef\uff0cerr.Error = ErrSyntax\uff1b\u5982\u679c\u7ed3\u679c\u8d85\u51fa\u7c7b\u578b\u8303\u56f4err.Error = ErrRange\u3002\u4ece\u4e0a\u9762\u7684\u63cf\u8ff0\u4e2d\uff0c\u4e5f\u53ef\u4ee5\u5f97\u77e5\uff0c\u8be5\u65b9\u6cd5\u8fd8\u53ef\u4ee5\u7528\u4e8e\u8f6c\u63622\u8fdb\u5236\u30018\u8fdb\u5236\u300116\u8fdb\u5236\u523010\u8fdb\u5236\uff0c\u4f8b\u5982\uff1a strconv.ParseInt(\u201c1110110\u2033,2,64),\u8fd4\u56de\u7ed3\u679c\uff1a118\u7279\u6b8a\u7684\u65b9\u6cd5\uff1a func Atoi(s string) (i int, err error) Atoi\u662fParseInt(s, 10, 0)\u7684\u7b80\u5199\u3002 uint uint8 uint16 uint32 uint64 \u540c\u4e0a\uff0cParseUint\u7c7b\u4f3cParseInt\u4f46\u4e0d\u63a5\u53d7\u6b63\u8d1f\u53f7\uff0c\u7528\u4e8e\u65e0\u7b26\u53f7\u6574\u578b float32 float64 \u7528\u6cd5\u540c\u4e0a\uff0c\u5148\u4f7f\u7528\u00a0strconv.ParseFloat(s,64)\uff0c\u7136\u540e\u5f3a\u5236\u8f6c\u6362\u6210\u76f8\u5bf9\u5e94\u7684\u7c7b\u578b\u3002func ParseFloat(s [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[17],"tags":[],"class_list":["post-15517","post","type-post","status-publish","format-standard","hentry","category-docker"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/15517","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/comments?post=15517"}],"version-history":[{"count":1,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/15517\/revisions"}],"predecessor-version":[{"id":15518,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/15517\/revisions\/15518"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=15517"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=15517"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=15517"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}