Presentation is loading. Please wait.

Presentation is loading. Please wait.

CS 111: Introduction to Programming Midterm Exam NAME _________________ UIN __________________ 10/30/08 1.Who is our hero? 2.Why is this person our hero?

Similar presentations


Presentation on theme: "CS 111: Introduction to Programming Midterm Exam NAME _________________ UIN __________________ 10/30/08 1.Who is our hero? 2.Why is this person our hero?"— Presentation transcript:

1 CS 111: Introduction to Programming Midterm Exam NAME _________________ UIN __________________ 10/30/08 1.Who is our hero? 2.Why is this person our hero? 3.The smallest element in a computer to hold data is the ______________ 4.Base 10 has how many unique digits? 5.Base 16 has how many unique digits? 6.What are the Base 16 digits? 7.A single hexadecimal digit contains 8 bits. YES NO 8.A computer does what you ________ it to do not what you ________ it to do. 9.Computers are machines. YES NO 10.It takes a byte to make up two hexadecimal digits. Y ES NO 11.What is the controlling entity of a computer: hardware of software (circle one) 12.The primary operations of a computer are: input – output – process YES NO

2 13.Programs that tell a computer what to do are known as software YES NO 14.A motherboard is part of the Central Processing Unit (CPU) YES NO 15.ROM (Read-Only-memory) contains the code written by the computer programmer YES NO 16.RAM (Random-Access-memory) contains the code written by the computer programmer YES NO 17.Application software controls system resources YES NO 18.The most important step in program development is to Outline the Solution YES NO 19.All of the program development steps overlap YES NO 20.The hardest task in program development is gathering the requirements YES NO 21.Modularization is best used when the program is small and more controllable YES NO 22.There are three tools the programmer has available: Sequence; Repetition; Decision YES NO 23.Single and Dual IF statements are examples of the Loop structure YES NO

3 24. An IF statement can only two ways out of the decision YES NO 25. An IF statement must always have an ELSE keyword YES NO 26. An IF statement without an ELSE is not allowed YES NO 27. IF A > B THEN where A = 4 and B = 8 is this statement TRUE or FALSE 28. IF A 22 THEN if A = 4 and B = 22 is the result TRUE or FALSE 29. All logic problems can be solved by using the three structures: Sequence, Looping, Decision YES NO 30.This is a sample of a Loop structure YES NO

4 31. This is a Decision structure YES NO 32. This is a Sequence structure YES NO 33.This is a correct loop design YES NO

5 34. This is a legal use of the decision structures YES NO 35.Name the symbols

6 36. A variable is a memory location where the contents can vary YES NO 37. A variable can have a name for programming purposes YES NO 38. A piece of data called a constant can be named and the data cannot be changed YES NO 39. A literal is a named piece of data that is the data itself YES NO 40.Local variables are obtainable from any program in any module YES NO 41. An = sign is an Assignment Operator YES NO 42. With an assignment, anything on the left side of the = sign is placed into the item on the right side YES NO 43. A = B + C Where A = 5, B = 4, C = 3 When this is complete the value in A will be 7 YES NO means addition YES NO 45. / means division YES NO 46. * means multiplication YES NO means subtraction YES NO

7 48. The Relational Operator = means “equal to” YES NO 49. The Relational Operator < means “less than” YES NO 50. The Relational Operator > means “greater than” YES NO 51. The Relational Operator >= means “greater than or equal to” YES NO 52. The Relational Operator <= means “less than or equal to” YES NO 53. The Relational Operator <> means “not equal to” YES NO 54. This is a good IF statement YES NO IF A = 5 AND B = C THEN false path ELSE true path ENDIF 55. This is a good IF statement YES NO IF A = 5 AND B = C THEN true path ENDIF

8 56. The program will not be converted to an executable if there is a syntax error YES NO 57.If a logical error occurs, the program will run but the results will be incorrect YES NO 58.Logical errors are more difficult to find than syntax errors YES NO % of computer programming is planning, not writing code YES NO 60.Documentation is very important as it will help with future problems and enhancements YES NO


Download ppt "CS 111: Introduction to Programming Midterm Exam NAME _________________ UIN __________________ 10/30/08 1.Who is our hero? 2.Why is this person our hero?"

Similar presentations


Ads by Google