See inside first and look the codes. Next, click the green flag and move your mouse. I used sqrt to calculate. And don't forget fullscreen. Hope you enjoy the project!
My K5 Homework for the idea.