-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathyang.py
More file actions
50 lines (43 loc) · 775 Bytes
/
yang.py
File metadata and controls
50 lines (43 loc) · 775 Bytes
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
#EXERCISE 2.1
print("EXERCISE 2.1")
print(01)
print(010)
print(0100)
print(01000)
#EXERCISE 2.2
print("EXERCISE 2.2")
5
x = 5
x + 1
print(5)
print("x=5")
print(x+1)
#EXERCISE 2.3
print("EXERCISE 2.3")
width = 17
height = 12.0
delimiter = '.'
print (width / 2)
print (width / 2.0)
print (height / 3)
print (1 + 2 * 5)
print (delimiter * 5)
#EXERCISE 2.4
print("EXERCISE 2.4")
print("PART 1")
pi = 3.141592653589732
r = 5
volume = 4/3.0*pi*r*r*r
print(volume)
print("PART 2")
cover_price = 24.95
discount_price = .4*cover_price
first_copy_shipping = 3
additional_shipping = .75
cost_60_books = discount_price*60+first_copy_shipping+additional_shipping*59
print(cost_60_books)
print("PART 3")
print(8.25*1 + 7.2*3)
print(.85*60)
print("I RETURN AT AROUND")
print("7:22")