Question: Find and fix the error in the if - else statement. 1 2 3 4 5 6 7 8 user _ num = int (

Find and fix the error in the if-else statement.
1
2
3
4
5
6
7
8
user_num = int(input()) # Program will be tested with values: 1,2,3,0.
if user_num =2:
print('Num is equal to two')
else:
print('Num is not two')
If user_num1 is less than 0, output 'user_num1 is negative'.
If user_num2 is greater than 15, assign user_num2 with 1.
Otherwise, output 'user_num2 is less than or equal to 15'.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!