COSC 101 expression practice (beta!)

Report any problems to jsommers@colgate.edu

Generate expressions using these types:






# Assume the following assignments have been made in Python
a = -2
b = 5
c = True
d = 2.0
e = -1.0
ExpressionYour Answer
1. not c != True True
2. a % (3+1) * a -4
3. a / 1 -2.0
4. -int(e) 1
5. -b / 4 -1.25
6. a < 2.0 True
7. -(b % abs(b) / -2) 0.0
8. b <= d or False False
9. a // 4 + 7 6
10. not not c True
Check Answers