biggest of two no's with out using if condition statement

Answer Posted / agalya

#include <stdio.h>
#include <math.h>
void main()
{
int m1,m2,a,b;
clrscr();
printf("Enter the First Number\n");
scanf("%d",&a);
printf("Enter the Second Number\n");
scanf("%d",&b);
m1=max(a,b);
m2=min(a,b);
printf("The Bigest No is==%d\n",m1);
printf("The Smallest No is==%d\n",m1);
}

Is This Answer Correct ?    2 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is union and structure?

569


Process by which one bit pattern in to another by bit wise operation is?

613


What is the stack in c?

714


How do I convert a string to all upper or lower case?

624


What is the size of enum in bytes?

581






What is data structure in c programming?

569


What is meant by initialization and how we initialize a variable?

581


1) There is a singing competition for children going to be conducted at a local club. Parents have been asked to arrive at least an hour before and register their children’s names with the Program Manager. Whenever a participant registers, the Program Manager has to position the name of the person in a list in alphabet order. Write a program to help the Program Manager do this by placing the name in the right place each time the Program Manger enters a name. The Logic should be written in Data Structures?

1909


the real constant in c can be expressed in which of the following forms a) fractional form only b) exponential form only c) ascii form only d) both a and b

1903


Can a pointer be null?

558


What is getch() function?

645


What is %d used for?

580


What are the similarities between c and c++?

593


What is the return type of sizeof?

588


Is null a keyword in c?

730