在Ruby 中 ** 是“次方” 的意思。 ... irb(main):006:0> Math.sqrt(9) => 3.0 ... 也就是呼叫 sqrt 方法,並傳遞9 作為參數。sqrt 正是“square root” 平方根的意思。
確定! 回上一頁