waglekiran919
waglekiran919 waglekiran919
  • 18-02-2021
  • Computers and Technology
contestada

a c program to check the greaster number among the two entered number using if else statement​

Respuesta :

tonb
tonb tonb
  • 18-02-2021

Answer:

#include <stdio.h>

int main(void) {

 int number1, number2;

 printf("Enter first number: ");

 scanf("%d", &number1);

 printf("Enter second number: ");

 scanf("%d", &number2);

 if (number1 > number2) {

   printf("%d is greater than %d!", number1, number2);

 } else if (number2 > number1) {

   printf("%d is greater than %d!", number2, number1);  

 } else {

   printf("%d is equal to %d!", number1, number2);

 }

}

Answer Link

Otras preguntas

how many sig figs are in the measurment 10010m
An ocean currents map is shown. On the map the locations for San Diego, California and Savannah, Georgia are marked. There is a looping current from the north p
is? 2s 2p 3s 3p 4s2 3d10 4p6
Work out the mean for the data set below: 67005, 67004, 67006, 67006, 67005, 67005, 67004, 67005
4) fill in the blanks with the following options: a) eukaryotic b) prokaryotic 1)bacteria______; bacteria, blue-green algae, spirochetes 2)archaea______; halop
8. Solve the equation. Check your solution, if possible. y - 12 = 9
LABEL THE DIAGRAM OF THE LEAF
845 ÷ 73 Divide. What is the remainder?
What is the advantage of using technology such as NASA's Global Precipitation Measurement mission for predicting weather? It uses several radars instead of rai
There are ten bird baths in a park. On the first day of​ spring, the bird baths are filled. Several weeks​ later, the overall change in the water level is found