write a c program to find largest of three numbers using simple if only for one time.
Answer Posted / 1160
#include<stdio.h>
#include<conio.h>
int main()
{
int a,b,c,max;
scanf("%d %d %d",&a,&b,&c);
if (a>b && a>c)
{
printf("%d",a);
}
max=(b>c)&&(c>a)?printf("%d",b):printf("%d",c);
return max;
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What are the types of pointers in c?
Explain what could possibly be the problem if a valid function name such as tolower() is being reported by the c compiler as undefined?
what do you mean by enumeration constant?
Why do we write return 0 in c?
Is a pointer a kind of array?
What is a static function in c?
How is pointer initialized in c?
I need previous papers of CSC.......plz help out by posting them.......
What is bss in c?
Write a program to maintain student’s record. Record should
not be available to any unauthorized user. There are three
(3) categories of users. Each user has its own type. It
depends upon user’s type that which kind of operations user
can perform. Their types and options are mentioned below:
1. Admin
(Search Record [by Reg. No or Name], View All Records,
Insert New Record, Modify Existing Record)
2. Super Admin
(Search Record [by Reg. No or Name], View All Records,
Insert New Record, Modify Existing Record, Delete Single Record)
3. Guest
(Search Record [by Reg. No or Name], View All Records)
When first time program runs, it asks to create accounts.
Each user type has only 1 account (which means that there
can be maximum 3 accounts). In account creation, following
options are required:
Login Name: <6-10 alphabets long, should be unique>
Password: <6-10 alphabets long, should not display
characters when user type>
Confirm Password:
Write a program in "C" to calculate the root of a quadratic equation ax^2+bx+c=0, where the value of a,b & c are known.
difference between Low, Middle, High Level languages in c ?
Explain the use of 'auto' keyword in c programming?
When should you use a type cast?
List some of the dynamic data structures in C?