Q. Write a program to read two numbers and print their quotient and remainder.

Answer :-

num1 = int (input ("Enter the first number :- "))
num2 = int (input ("Enter the second number :- "))
print ("Quotient :- ", num1 // num2 )
print ("Remainder :- ", num1 % num2)

Output :-

Enter the first number :- 10
Enter the second number :- 2
Quotient :-  5
Remainder :-  0

>>> 

Enter the first number :- 4567
Enter the second number :- 8
Quotient :-  570
Remainder :-  7

>>> 


2 Comments

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post