Computer Science, asked by advpks5791, 1 month ago

write a program to assign two values of int data type and display the sum, difference, quotient and reminder​

Answers

Answered by Aishwarya3355
0

include <stdio.h>

int main() {

int dividend, divisor, quotient, remainder;

printf("Enter dividend: ");

scanf("%d", &dividend);

printf("Enter divisor: ");

scanf("%d", &divisor)

// Computes quotient

quotient = dividend / divisor;

// Computes remainder

remainder = dividend % divisor;

printf("Quotient = %d\n", quotient);

printf("Remainder = %d", remainder);

return 0;

This is a program in c for finding quotient and remainder

if u wanted sum and diff then just put

for ex if the integers are a and b,

just do ,

sum = a+b;

then print sum

for difference

diff= a-b;

then print diff

HOPE IT HELPS。◕‿◕。

Similar questions