VBScript Sqr Function
VBScript Tutorial | VBScript Usage | VBScript Variables | VBScript Procedures | VBScript Conditionals | VBScript Looping | VBScript Summary | VBScript Examples | VBScript Functions | VBScript Keywords
The Sqr function returns the square root of a number.
Note: The number parameter cannot be negative.
Syntax
Sqr(number)
| Parameter | Description |
|---|---|
| number | Required. A valid numerical expression greater than 0. |
Example
document.write(Sqr(9) & "") document.write(Sqr(0) & "
") document.write(Sqr(47))
Output:
- 3
- 0
- 6.85565460040104
YouTip