Create a program that presents the user with a multiple choice quiz. The user wi
ID: 3659863 • Letter: C
Question
Create a program that presents the user with a multiple choice quiz. The user will be presented with five questions, a question at a time with the choice of four possible answers. The user will input an answer "a", "b", "c", "d". in response to a question. The program will keep track of the right or wrong scores for each question and give a final grade report once the quiz is finished. The final report will give right or wrong for each question as well as the average grade and assign a letter grade based on the final average. The user should be given the choice to take the quiz again or to quit the program.Explanation / Answer
#include int main() { int ch=1,i; while(ch==1) { printf(" 1. What is the correct value to return to the operating system upon the successful completion of a program A. -1 B. 1 C. 0 D. Programs do not return a value."); printf(" Enter Your choice"); char ch1; scanf("%c",&ch1); if((ch1=='C')||(ch1=='c')) { i++; printf(" correct answer"); } else { printf(" in correct answer"); } printf(" 2. What is the only function all C programs must contain A. start() B. system() C. main() D. program() "); printf(" Enter Your choice"); char ch2; scanf("%c",&ch2); if((ch2=='C')||(ch2=='c')) { printf(" correct answer"); i++; } else printf(" in correct answer"); printf(" 3. What punctuation is used to signal the beginning and end of code blocks A. { } B. -> andRelated Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.