Program 3
Write a program that uses a for loop to print the numbers 8, 11, 14, 17, 20, . . . , 83, 86, 89.
Program:
for i in range(8,90,3):
print(i,end=" ")
Output:
8 11 14 17 20 23 26 29 32 35 38 41 44 47 50 53 56 59 62 65 68 71 74 77 80 83 86 89
Program 30 Write a Python class to implement pow(x, n). class Pow1:...
No comments:
Post a Comment