Program to find larger of the two numbers without using if-else,while,for,switch
Answer Posted / vara
#include<stdio.h>
void main()
{
int a,b;
printf("enter a and b values");
scanf("%d%d",&a,&b);
a>b?printf("%d",a):printf("%d",b);
}
Is This Answer Correct ? | 89 Yes | 11 No |
Post New Answer View All Answers
When should you use a type cast?
What is pass by value in c?
what is stack , heap ,code segment,and data segment
What is meant by 'bit masking'?
write a program that declares an array of 30 elements named "income" in the main functions. then cal and pass the array to a programmer-defined function named "getIncome" within the "getIncome" function, ask the user for annual income of 30 employees. then calculate and print total income on the screen using the following function: "void getIncome ( ai []);
What is the use of linkage in c language?
How will you print TATA alone from TATA POWER using string copy and concate commands in C?
I have seen function declarations that look like this
With the help of using classes, write a program to add two numbers.
Is main an identifier in c?
using only #include
Explain pointers in c programming?
PROGRAM TO WRITE CONTENTS OF 1 FILE IN REVERSE TO ANOTHER FILE,PROGRAM TO COPY 1 FILE TO ANOTHER BY SPECIFYING FILE NAMES AS COMMAND LINE
How to set file pointer to beginning c?
Program will then find the largest of three numbers using nested if-else statements. User is prompted to enter three numbers. Program will find the largest number and display it on the screen. All three numbers entered by the user are also displayed. If user enters 21, 33, and 5, the output should be as follows: You entered: 21, 33 and 5. The largest number is 33.