The TransCompilator

Solved LeetCode program · 239 of 1,000

#0319 · Bulb Switcher

Medium Math chunk-05.md

Original English source

The number is 3. The root is 1.
Repeat while root times root is at most number.
Add 1 to root.

Show root minus 1.

Open in Playground Browse all 1,000 problems

Expected stdout

1