All Downloads are FREE. Search and download functionalities are using the official Maven repository.

javacc-6.1.2.examples.Interpreter.sqrt.spl Maven / Gradle / Ivy

There is a newer version: 7.0.13
Show newest version

int val;

read val;
int sqrt;

sqrt = 1;

while (sqrt * sqrt <= val && ((sqrt + 1) * (sqrt + 1)) <= val)
  sqrt = sqrt + 1;

write sqrt




© 2015 - 2024 Weber Informatics LLC | Privacy Policy