QUESTION 1
Write the following number guessing game in Python: Python
‘thinks’ of an integer between 1 and 100 (i.e., generates a random
number) and you have to guess it. If your guess is too high or too
low, the script must say so. If your guess is correct, a message of
congratulations must be displayed. Use the following pseudocode: 1.
Generate random integers 2. Ask the user to guess 3. While the
guess is wrong a. If the guess is too low i. Tell her it is too low
b. Otherwise i. Tell her it is too high c. Ask the user for a new
guess 4. Polite congratulations 5. Stop
QUESTION 2
Evaluate (Solve) the following quadratic equations using either
sympy.symbols(), sympy.solve()s and/or sympy.factor():
b) x 2 + 3x – 4 = 0
d) 𝑥 ଶ + cos (𝑥)
g) -4x² - 7x +12 = 0
j) 5x² - 2x - 9 = 0
QUESTION 3
Evaluate (Solve) the following equations will all evaluate to
zero at the correct solution.
a) 0 = 0.85 ⋅ 𝑣𝑎𝑝 + 0.106 ⋅ 𝑙𝑖𝑞 − 55 kg/s
0 = 0.15 ⋅ 𝑣𝑎𝑝 + 0.894 ⋅ 𝑙𝑖𝑞 − 45 𝑘g/s
b) 4y + 3x = 100
4y -19x =12
g) 3x -14y =0
x -4y + 1=0
QUESTION 1 Write the following number guessing game in Python: Python ‘thinks’ of an integer between 1 and 100 (i.e., ge
-
answerhappygod
- Site Admin
- Posts: 899604
- Joined: Mon Aug 02, 2021 8:13 am
QUESTION 1 Write the following number guessing game in Python: Python ‘thinks’ of an integer between 1 and 100 (i.e., ge
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!