This quiz works best with JavaScript enabled. Home > Grammar > Syntax > Syntax And Logic Errors – Quiz 2 🏠 Homepage 📘 Download PDF Books 📕 Premium PDF Books Syntax And Logic Errors Quiz 2 (19 MCQs) Quiz Instructions Select an option to see the correct answer instantly. 1. Once a logical condition in an IF statement is TRUE, all other statements are are ignored A) True. B) False. C) All the above. D) None of the above. Show Answer Correct Answer: A) True. 2. What is the significance of the program running without errors at the end? A) It means there are no syntax errors. B) It means there are no logic errors. C) It means the program is robust. D) It means the program is perfect. Show Answer Correct Answer: B) It means there are no logic errors. 3. These types of errors are generally detected by the IDE A) Syntax Error. B) Logic Error. C) All the above. D) None of the above. Show Answer Correct Answer: A) Syntax Error. 4. What is the main issue with the program's validation of user input? A) It doesn't recognize the variable choice. B) It doesn't prompt the user to enter a choice. C) It doesn't run the program. D) It accepts invalid input. Show Answer Correct Answer: D) It accepts invalid input. 5. Which statement best describes logic errors? A) An error in a program that causes it to produce incorrect ouputs but not a crash. B) An error in a program that causes it to crash. C) An error in the program caused by mis-spelt instructions. D) An error in a program caused by hardware failure. Show Answer Correct Answer: A) An error in a program that causes it to produce incorrect ouputs but not a crash. 6. Syntax errors are caused by incorrectly typed source code. A) True. B) False. C) All the above. D) None of the above. Show Answer Correct Answer: A) True. 7. Using incorrectly named programming functions is an example of what type of error A) Syntax Error. B) Logic Error. C) All the above. D) None of the above. Show Answer Correct Answer: A) Syntax Error. 8. Go to:https://apclassroom.collegeboard.org/d/81ryd5zt11?sui=8, 1I will be checking if you watched the entire video.Select the statement that does NOT contain a syntax error. A) System.out.println("Hello World");. B) System.out.println("hello world");. C) System.out.println("Hello World"). D) System.out.printl("Hello World");. Show Answer Correct Answer: B) System.out.println("hello world");. 9. A program will compile if there is a syntax error. A) True. B) False. C) All the above. D) None of the above. Show Answer Correct Answer: B) False. 10. Which statement contains a syntax error A) Print("Hello"). B) PRINT("Hello"). C) Print("hello"). D) Print("HELLO"). Show Answer Correct Answer: B) PRINT("Hello"). 11. What is iterative testing? A) Testing completed after an error is found. B) Random tests on a computer program. C) Test completed as the program is being coded. D) Test which are planned. Show Answer Correct Answer: C) Test completed as the program is being coded. 12. What type of error is the use of 'and' instead of 'or' in the while statement? A) Syntax Error. B) Semantic Error. C) Runtime Error. D) Logic Error. Show Answer Correct Answer: D) Logic Error. 13. If there is a logic error in the code, the program will NOT run. A) True. B) False. C) All the above. D) None of the above. Show Answer Correct Answer: B) False. 14. Testing while coding a program is called? A) Development Testing. B) Coder Testing. C) Terminal Testing. D) Iterative Testing. Show Answer Correct Answer: D) Iterative Testing. 15. What is the purpose of the while loop in the program? A) To save the game. B) To validate the input. C) To play a new game. D) To print the menu commands. Show Answer Correct Answer: B) To validate the input. 16. A program will still run even with this type of error A) Syntax Error. B) Logic Error. C) All the above. D) None of the above. Show Answer Correct Answer: B) Logic Error. 17. If num < 5:print("The number is larger than 5") A) Syntax Error. B) Logic Error. C) All the above. D) None of the above. Show Answer Correct Answer: B) Logic Error. 18. What type of input is accepted by the program even though it should be considered invalid? A) No input. B) Symbol input. C) Character input. D) Negative number input. Show Answer Correct Answer: C) Character input. 19. Modern IDEs can spot syntax errors are you type your code A) True. B) False. C) All the above. D) None of the above. Show Answer Correct Answer: A) True. ← PreviousRelated QuizzesGrammar QuizzesSyntax And Logic Errors Quiz 1Subordination QuizSyntactic Transformations QuizSyntax QuizWord Order Adjectives QuizWord Order And Adverbs QuizWord Order Sentences Quiz 🏠 Back to Homepage 📘 Download PDF Books 📕 Premium PDF Books