<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??碼云GVP開源項目 12k star Uniapp+ElementUI 功能強大 支持多語言、二開方便! 廣告
                [TOC] ## math包運算 > 僅列出常用的函數,如果要查詢更多函數,可參考 https://mp.weixin.qq.com/s/d1D1VUbTjYnPS6cJj3K-Cw ~~~ fmt.Println(math.IsNaN(3.4)) //判斷是否為非數字___結果:false fmt.Println(math.Ceil(1.000001)) //向上舍入為最接近的整數___結果:2 fmt.Println(math.Floor(1.999999)) //向下舍入為最接近的整數___結果:1 fmt.Println(math.Trunc(1.999999)) //只返回整數部分___結果:1 fmt.Println(math.Abs(-1.3)) //取絕對值___結果:1.3 fmt.Println(math.Max(-1.3, 0)) //獲取兩數之間的最大值___結果:0 fmt.Println(math.Min(-1.3, 0)) //獲取兩數之間的最小值___結果:-1.3 ~~~ ## rand包 ### rand.Seed(time.Now().UnixNano())作用 > 設置隨機數種子后,才能保證程序每次運行的隨機數都是動態的 ### 兩數之間隨機 ~~~ rand.Seed(time.Now().UnixNano()) min, max := -60, 60 // Intn(n)、Int31n(n)、Int63n(n) 返回[0,n]之間的隨機數 fmt.Println(rand.Intn(max-min) + min) ~~~ > 運行結果 -32
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看