unitiii

6
Unit III: Program Testing and Debugging Testing (4+14+4=22) Q 1. Testing is a____if a program does not work correctly. A Failure B Success C Complete D Partial *Q 2. White box testing is of the following form: A Test engineer has complete knowledge of the code and functionality of the program, and testing is based on this knowledge. B Test engineer has no knowledge of the code but has full knowledge of the functionality of the program. C Test engineer has complete knowledge of the code but has no knowledge of the functionality of the program. D Test engineer has no knowledge of the code and does not know how the code functions, and testing is based mostly on requirement sheets. Q 3. The inputs for developing a test plan are taken from A Project plan B Business plan C Support plan D None of the above Q 4. To make a program useful and error free two processes are important. They are _______. A planning & Testing B Testing & Debugging C Planning & Debugging D Debugging & linking

Upload: abhijith-suboyin

Post on 06-Mar-2016

212 views

Category:

Documents


0 download

DESCRIPTION

Test engineer has no knowledge of the code and does not know how the code functions, and testing is based mostly on requirement sheets. Test engineer has complete knowledge of the code and functionality of the program, and testing is based on this knowledge. Test engineer has no knowledge of the code but has full knowledge of the functionality of the program. Test engineer has complete knowledge of the code but has no knowledge of the functionality of the program. B C D

TRANSCRIPT

Unit III: Program Testing and Debugging

Testing (4+14+4=22)Q 1. Testing is a____if a program does not workcorrectly.A FailureB SuccessC CompleteD Partial*Q 2. White box testing is of the following form:A Test engineer has complete knowledge of the code andfunctionality of the program, and testing is based on thisknowledge.BTest engineer has no knowledge of the code but has full knowledgeof the functionality of the program.CTest engineer has complete knowledge of the code but has noknowledge of the functionality of the program.DTest engineer has no knowledge of the code and does not knowhow the code functions, and testing is based mostly on requirementsheets.Q 3. The inputs for developing a test plan are taken fromA Project planB Business planC Support planD None of the aboveQ 4. To make a program useful and error free twoprocesses are important. They are _______.A planning & TestingB Testing & DebuggingC Planning & DebuggingD Debugging & linking

Unit III: Program Testing and Debugging

Syntax ErrorsQ 1. Which of the following is a type of error?A compile timeB syntaxC LogicalD All the aboveQ 2. Which of the following is a type of an error?A Syntax ErrorB Logical ErrorC Run-time ErrorD All of aboveQ 3. Which of the following are syntax errorsA Incorrect punctuationB Missing semicolonC Missing DeclarationsD All of the aboveQ 4. Which of the following errors can be detected by a` Compiler ` ?A Illegal charactersB Semantic errorsC use of undefined variable namesD all of theseQ 5. Syntax errors are ___________ than logical error.A easy to removeB difficult to removeC difficult to detectD None of aboveUnit III: Program Testing and Debugging Prepared by: Mr. Laxman J. DeokateQ 6. Syntax error typically involve ________ .A Incorrect punctuationB Invalid charactersC Not using separators such as a semicolonD All of aboveQ 7. A program can not be compiled until all of its_____ errors have been corrected.A logicalB Run timeC SyntaxD All of the above

Unit III: Program Testing and Debugging

Q 8. The errors that can be pointed out by the compiler areA Syntax errorsB Semantic errorsC Logical errorsD None of the above

Logical (Run-time) ErrorsQ 9. The printf() function returns which value when anerror occures?A positive valueB zeroC Negative valueD None of these\Q 10. In computer programming, a logical error is a bugin a program that causes the program .......A to operate incorrectlyB to failC to go into an infinite loopD All of the aboveQ 11. Errors that occur when rules of programming language are not followed________A logical errorsB syntax ErrorsC User ErrorsD Program ErrorsQ 12. Run Time Errors are encountered at the time of _________A ExecutionB CompilationC CodingD SavingQ 13. Due to logical error program will produce _______ .A Incorrect outputB Required outputC GarbageD Incorrect output or garbage

Unit III: Program Testing and Debugging

*Q 14. Logical error in a program will ___________ error message.A ProduceB Not produceC do nothingD All of above

Debugging*Q 1. Which of the following would be the most appropriate way to debug a problematic code?AComment out the whole code and progressively uncomment it, tillyou find the errorBPut appropriately named print statements throughout the code andfollow the output to find the errorC Both of the aboveD None of the aboveQ 2. A Debugger is_____A a compilerB an active debuggerC a C interpreterD a analyzing tool in CQ 3. ______________ being a reactive process, it mustbe carried out when errors are found in a program.A TestingB DebuggingC EvaluatingD None of the aboveQ 4. Program errors are known as ____________, andthe process of detecting and correcting these errorsis called ______________.A Virus, Testing.B Bugs, Debugging.C Defects, Checking.D None of these.

Unit III: Program Testing and Debugging