biggest of two no's with out using if condition statement
Answer Posted / sarvanm
#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=abs((a+b)/2);
m2=abs((a-b)/2);
printf("The Bigest No is==%d\n",m1+m2);
printf("The Smallest No is==%d\n",m1-m2);
}
Is This Answer Correct ? | 15 Yes | 1 No |
Post New Answer View All Answers
Explain about C function prototype?
Why is c so important?
What is strcpy() function?
any C program contains only one function, it must be a) void () b) main () c) message () d) abc ()
What is difference between union All statement and Union?
What is assignment operator?
a character or group of characters that defines a register,or a part of storage a) memory b) byte c) address d) linear list
how could explain about job profile
Explain why C language is procedural?
Can you apply link and association interchangeably?
how much salary u want ? why u join in our company? your domain is core sector why u prefer software ?
What is assert and when would I use it?
Explain what are bus errors, memory faults, and core dumps?
Can we replace the struct function in tree syntax with a union?
What is boolean in c?