VBScript Oct 函數
定義和用法
Oct 函數可返回表示指定數字八進制值的字符串。
注釋:如果 number參數不是整數,則在進行運算前將其四舍五入為最接近的整數。
語法
Oct(number)
參數 | 描述 |
---|---|
number | 必需的。任何有效的表達式。 如果 number是:
|
實例
document.write(Oct(3)) document.write(Oct(5)) document.write(Oct(9)) document.write(Oct(10)) document.write(Oct(11)) document.write(Oct(12)) document.write(Oct(400)) document.write(Oct(459)) document.write(Oct(460))
分別輸出:
3 5 11 12 13 14 620 713 714