Write a program in C for showing working of different
logical operator in C.
Your program should guide users with proper message/menu on
the console.
Answer Posted / chauhan varsha
#include<stdio.h>
void main()
{
int a=5,b=8,c=9,d=2;
clrscr();
if((a==b)&&(a==c))
{
printf("value is same. check 3 values using logical
operator..");
}
else if((a!>b) || (a!>c))
{
printf("value of a is not grater from b & c check
using logical operator or & not...");
}
getch();
}
Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
Write a program to reverse a given number in c?
What is the difference between text and binary i/o?
Where are c variables stored in memory?
How can a program be made to print the name of a source file where an error occurs?
What is hungarian notation? Is it worthwhile?
What are the different categories of functions in c?
What are the parts of c program?
Explain union.
What is sizeof in c?
What is wrong with this initialization?
Ow can I insert or delete a line (or record) in the middle of a file?
What is the purpose of type declarations?
Compare interpreters and compilers.
What is the size of enum in bytes?
1. Write a function to display the sum of two numbers in the following ways: By using (i) pass by value (ii) pass by address a. function with argument and with return value b. function with argument and without return value c. without argument , with return value d. without argument , without return value Note: Use pass by address.