-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpprint_demo.py
More file actions
65 lines (59 loc) · 1.25 KB
/
pprint_demo.py
File metadata and controls
65 lines (59 loc) · 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# pretty print
from pprint import pprint
nato = {
"A": "Alpha",
"B": "Bravo",
"C": "Charlie",
"D": "Delta",
"E": "Echo",
"F": "Foxtrot",
"G": "Golf",
"H": "Hotel",
"I": "India",
"J": "Juliet",
"K": "Kilo",
"L": "Lima",
"M": "Mike",
"N": "November",
"O": "Oscar",
"P": "Papa",
"Q": "Quebec",
"R": "Romeo",
"S": "Sierra",
"T": "Tango",
"U": "Uniform",
"V": "Victor",
"W": "Whiskey",
"X": "X-ray",
"Y": "Yankee",
"Z": "Zulu"
}
aqi_tbl = [
[0, 'good', 'green'],
[51, 'moderate', 'yellow'],
[101, 'unhealthy for sensitive groups', 'orange'],
[151, 'unhealthy', 'red'],
[201, 'very unhealthy', 'purple'],
[301, 'hazardous', 'maroon']
]
names = [
{'name': 'Peter', 'score': 5},
{'name': 'Jenny', 'score': 8},
{'name': 'Bruce', 'score': 7},
{'name': 'Ben', 'score': 10}]
menus = {
"Mocha": {"S": 20, "M": 25, "L": 30},
"Latte": {"S": 30, "M": 45, "L": 50},
"Espresso": {"S": 35, "M": 40, "L": 45},
}
if __name__ == "__main__":
# pprint(nato)
# print(aqi_tbl)
# print('-' * 80)
# pprint(aqi_tbl)
# print(names)
# print('-' * 80)
# pprint(names)
print(menus)
print('-' * 80)
pprint(menus)