You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
399 B
Python
24 lines
399 B
Python
import os
|
|
|
|
list1 = list(range(1, 11))
|
|
print(list1)
|
|
|
|
list2 = []
|
|
|
|
for i in range(1, 11):
|
|
a = str(i) + 'x' + str(i)
|
|
list2.append(a)
|
|
|
|
print(list2)
|
|
|
|
list3 = [x * x for x in range(1, 11)]
|
|
print(list3)
|
|
|
|
list4 = [x * x for x in range(1, 11) if x % 2 == 0]
|
|
print(list4)
|
|
|
|
list5 = [m + n + p for m in 'abcd' for n in 'xyz' for p in '123']
|
|
print(list5)
|
|
|
|
list6 = [d for d in os.listdir('/')]
|
|
print(list6) |