Netbyzz

#B034

Python :

#CODE = #B034
#1.while-loop
print("--------Method 1--------")
i = 1
while i <= 100:
    print(i, end=" ")
    i += 1

#2.for-loop
print("\n\n--------Method 2--------")
for i in range(1,101):
    print(i, end=" ")

#3.single line
print("\n\n--------Method 3--------")
print([i for i in range(1,101)])

Source Code