sqrt()

From Hack Wars Wiki

Jump to: navigation, search
Information for free function sqrt()
Function sqrt(float)
API Challenge
Description Returns a float representing the positive square root of the provided float



[edit] Example

If a challenge were to ask you for all the square roots of the float provided, the script would be:

float num = getInputFloat()
float possqr = sqrt(num);
float negsqr = sqrt(num)* (-1);
setOutputFloat(possqr);
setOutputFloat(negsqr);
Personal tools