From 71de11a8a4ea169b9db823dd2391ada072f0b765 Mon Sep 17 00:00:00 2001 From: Sandesh2003 <72540199+Sandesh2003@users.noreply.github.com> Date: Sat, 1 Oct 2022 19:59:42 +0530 Subject: [PATCH] Create Qutient --- Qutient | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 Qutient diff --git a/Qutient b/Qutient new file mode 100644 index 00000000..e8309095 --- /dev/null +++ b/Qutient @@ -0,0 +1,39 @@ +#include + +int main(){ + + int num1, num2, quot, rem; + + printf("Enter dividend: "); + + scanf("%d", &num1); + + printf("Enter divisor: "); + + scanf("%d", &num2); + + /* The "/" Arithmetic operator returns the quotient + + * Here the num1 is divided by num2 and the quotient + + * is assigned to the variable quot + + */ + + quot = num1 / num2; + + /* The modulus operator "%" returns the remainder after + + * dividing num1 by num2. + + */ + + rem = num1 % num2; + + printf("Quotient is: %d\n", quot); + + printf("Remainder is: %d", rem); + + return 0; + +}