Question

Write a program in C to find the student’s eligibility for admission into some academic program....

Write a program in C to find the student’s eligibility for admission into some academic program. Ask the user to enter three grades for Maths, Physics, and Chemistry. Then if: The student’s grade in Math is greater than 80 and in Physics is greater than 70, the student is eligible to study Engineering. The student’s grade in Physics is greater than 80 or Chemistry is greater than 90, the student is eligible to study Sciences. Otherwise, the student is not eligible to study in this college.

Homework Answers

Answer #1

Code:

#include<stdio.h>

int main()
{
   int maths,phy,chem;
   printf("\nEnter the Maths marks (out of 100):"); //input maths marks
   scanf("%d",&maths);
   printf("\nEnter the Physics marks (out of 100):"); //input physics marks
   scanf("%d",&phy);
   printf("\nEnter the Chemistry marks (out of 100):"); //input chemistry marks
   scanf("%d",&chem);
  
   printf("\nEntered marks:\n Maths:%d\tPhysics:%d\tChemistry:%d",maths,phy,chem);
  
   if((maths>80)&&(phy>70)) //checking condition 1
       printf("\nYou are eligible to study Engineering....");
      
   else if((phy>80)||(chem>90))
       printf("\nYou are eligible to study Sciences....");   //checking condition 2
      
   else                   //if both not satisfied
        printf("\nYou are not eligible to study in this college..!");
  
}

Output:

1)

2)

3)

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
C++ Write a program which accepts a numeric test score from the user. It will output...
C++ Write a program which accepts a numeric test score from the user. It will output the letter grade to the user corresponding to the score. Assume no “minus grades” (an A ranges from 90-100, B ranges from 80-89, C ranges from 70-79, D ranges from 60-69 and F is everything else.) Ensure that the score remains in the range of 0 to 100. As an example of the output: Enter your numeric grade and I will tell you your...
In this lab, you will write a program that creates a binary search tree based on...
In this lab, you will write a program that creates a binary search tree based on user input. Then, the user will indicate what order to print the values in. **Please write in C code** Start with the bst.h and bst.c base code provided to you. You will need to modify the source and header file to complete this lab. bst.h: #ifndef BST_H #define BST_H typedef struct BSTNode { int value; struct BSTNode* left; struct BSTNode* right; } BSTNode; BSTNode*...
In The New York Times, there is a column called “The Ethicist,” where some writer for...
In The New York Times, there is a column called “The Ethicist,” where some writer for the newspaper gives arguments in response to questions that are posed by readers. In the question below titled “Test Prep or Perp?,” Randy Cohen is the writer who gives an argument in reply to someone’s question about whether it’s ethical to use Adderall (the person’s name is withheld) to help take the L.S.A.T. (Law School Admission Test). I think that there is at least...
Assignment: What are the main arguments in the article? Please answer within 5 hours. It is...
Assignment: What are the main arguments in the article? Please answer within 5 hours. It is extremely urgent!!!!!!!!!!!!!!!!!!!!!!!! --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- BIOETHICS. Bioethics as a field is relatively new, emerging only in the late 1960s, though many of the questions it addresses are as old as medicine itself. When Hippocrates wrote his now famous dictum Primum non nocere (First, do no harm), he was grappling with one of the core issues still facing human medicine, namely, the role and duty of the...
What topics are covered in the following article? Please answer within 5 hours. It is extremely...
What topics are covered in the following article? Please answer within 5 hours. It is extremely urgent!!!!!!!!!!!!!!!!!!!!!!!! --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- BIOETHICS. Bioethics as a field is relatively new, emerging only in the late 1960s, though many of the questions it addresses are as old as medicine itself. When Hippocrates wrote his now famous dictum Primum non nocere (First, do no harm), he was grappling with one of the core issues still facing human medicine, namely, the role and duty of the physician....
What tools could AA leaders have used to increase their awareness of internal and external issues?...
What tools could AA leaders have used to increase their awareness of internal and external issues? ???ALASKA AIRLINES: NAVIGATING CHANGE In the autumn of 2007, Alaska Airlines executives adjourned at the end of a long and stressful day in the midst of a multi-day strategic planning session. Most headed outside to relax, unwind and enjoy a bonfire on the shore of Semiahmoo Spit, outside the meeting venue in Blaine, a seaport town in northwest Washington state. Meanwhile, several members of...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT