KnowledgeBoat Logo
|

Robotics & Artificial Intelligence

Write Python code to display the first ten terms of the following series:

1, 4, 9, 16, ……………

Python Control Flow

2 Likes

Answer

for i in range(1, 11):
    print(i*i, end=" ")

Output

1 4 9 16 25 36 49 64 81 100

Answered By

1 Like


Related Questions