You have an integer number N. Read it from the standard input and print all squares of natural numbers that do not exceed N in ascending order.
While loops
Squares of natural numbers
Report a typo
Sample Input 1:
50Sample Output 1:
1
4
9
16
25
36
49Sample Input 2:
49Sample Output 2:
1
4
9
16
25
36
49Write a program in Kotlin
fun main() {
// put your code here
}
___
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.