Student Test Booklet s1

STUDENT TEST BOOKLET

Scoring Breakdown: 4 = 50/50, 3 = 45/50, 2 = 30/50, 1 = 20/50, 0 = 0/50

This test section contains TWELVE multiple-choice and ONE open-response (short-answer) questions. Please mark your answers for the multiple-choice questions in the spaces provided on your Student Response Booklet. Mark only one answer for each question. If you do not know the answer, make your best guess. DO NOT WRITE ANY ANSWERS IN THIS TEST BOOKLET. WHEN YOU FINISH, DO NOT WORK ON ANY OTHER TEST SECTION.
1. / Craig has been asked by his boss at Video Plus to place the entire movie inventory into a computer-based program for employees to use to select movies for purchase. Craig wishes to design a program in which the user can select multiple items from the store to purchase at once. What selection should Craig make?
A. / Utilize option buttons that are built within a frame so that multiple items can be selected.
B. / Insert a command button that will require the user to type in the movie title and then select a search button that will display the movie on the program screen.
C. / Write an If statement that will check to see what movie has been selected from a timer control hidden within the program.
D. / Add check boxes into a frame so that multiple items can be selected.
2. / Kim is currently developing a program that will allow car shoppers to select and view an interior color when an option button is selected. Which of the following code segments should be placed into a command button so that when option1 is selected, image 1 appears on the screen?
A. / If option1.value = 1 then
Image1.visible = true
End if
B. / If option1.value = true then
Image1.visible = true
End if
C. / Image1.visible = true
D. / If option1.value = true then
Image1.visible = false
End if
3. / Ken has been asked to speak to all junior programmers about the selection process between option buttons and check boxes. Which of the following statements would be accurate information for Ken to include within his presentation?
A. / Check boxes are used to help a user select multiple items within a program. Option buttons are used to help a user make a single selection within a program.
B. / Check boxes require less code than an option button within a program.
C. / Check boxes and option buttons are only different based on appearance within the program. The coding for both buttons is identical.
D. / Check boxes and option buttons should not be utilized within the same program due to both being selection control buttons. The coding within the program would produce an error message.

PLEASE GO ON TO THE NEXT PAGE è

4. / Which of the following code segments would add 50 cents to a variable called total if check5 has been selected when a command button is pressed?
A. / Label2.caption = Total +.50
B. / If check5.value = true then
Total = total + .5
End if
C. / If total < 0 then
Total + .50
End if
D. / If check5.value = 1 then
Total = total + .5
End if
5. / Label2.caption = val(Text1.text) + val(label3.caption).
Which of the following statements explains the operation of the above section of code?
A. / The value of text1 will be added to the value of label3.caption and will be stored into a variable
B. / Label2 will be added to the values found in text1 and label3
C. / Text1 and label3 will be added together and the result will be placed in label2
D. / The program will issue an error due to label3 not being the same type as the text box being used with the first value.
6. / Dot is working on listing her favorite songs in a combo box within a visual basic program. Dot wants a picture of the band to display when a song that they perform is selected within the combo box. What code would Dot need to use within her combo box to make the pictures display correctly?
A. / Image1.visible = true will be placed into the list section for each song that is represented. The only change in code will be the number that appears after the word Image
B. / If combo1.text = “Insert Song Name” Then
Image1.visible = true
Image2.visible = false **All other images would be set to false below this section.
End if
C. / If combo1.value = “Insert Song Name “ then
Image1.visible = true
End if
D. / The code would be inserted into multiple sections of the program so that each group is included and a picture would show up correctly on the screen.

PLEASE GO ON TO THE NEXT PAGE è

7. / Buck has been asked by the general manager at Big City Auto Center to design an application that will allow the entire car and truck inventory to be included. Buck has decided to utilize a combo box within the application. Which of the following statements is not true concerning combo boxes?
A. / The items to be displayed in a combo box are entered into the list property
B. / The text property displays the active/currently-selected item within the combo box.
C. / Combo boxes save space within a program due to there design and setup
D. / Combo boxes require code to be copied into two places so that an item can be selected and then be displayed onto the screen.
8. / Billy Jo has been asked to use more frames within his program design. Which statement below will best explain their overall purpose to Billy Joe?
A. / Frames allow items to be grouped and moved easily within the program design screen.
B. / Frames allow program code to be easily copied form one section of a program into another section.
C. / Frames add extra graphical design into a program by allowing word art and other features to be inserted.
D. / Frames add security within program design and allow the user to make multiple selections with just a single click.
9. / Stu was recently assigned the task of correcting minor errors within a junior programmers street racing game. The game allows the user to select modifications using a combo box but when the reset button is pressed the modification remains in the combo box. What code does Stu need to insert into the reset button so that the information is removed?
A. / clear
B. / Combo1.text = “ “
C. / Combo1.list = “ “
D. / Combo1.index = “ “

PLEASE GO ON TO THE NEXT PAGE è

Use the following article to answer questions 10 –12

Programming Languages

The language a computer can understand (called "machine code") is composed of strings of zeros and ones. This smallest element of a computer’s language is called "a bit" ? 0 or 1. Four bits are a nibble. Two nibbles (8 bits) equal a byte. The words of a computer language are the size of a single instruction encoded in a sequence of bits (for example, many computers speak a language with words that are '32-bits' long).

As machine code is extremely difficult to work with, a type of language called Assembly was soon developed. Using an assembly language, programmers use series of mnemonics that are then translated by a program into machine code that the computer can understand. However, assembly is very similar to machine code in that all procedures have to be spelt out in exact detail in a process that is extremely difficult, slow and prone to errors.

Translators (Compilers and Interpreters)

Grace Hopper is credited with pioneering the idea of a compiler to translate some more human-friendly language into the language of a computer. These more human-friendly languages are called higher level languages and were developed to allow programmers to concentrate more closely on the abstract problem to be solved rather than all the painful detail required for machine code or assembly language programming.

A compiler converts source code written in some high-level language into executable machine code (also called binary code or object code). The resulting machine code can only be understood by a specific processor, such as a Pentium or PowerPC.

An interpreter translates either source code or tokens into machine code, one instruction at a time, as the program is run. An interpreter does not generate machine code from a source program.

High level languages

One of the first 'higher level' languages that gets wide use is FORTRAN, first released in 1957. This language is very good at number crunching, but not so good at input and output. COBOL, released soon after, was "designed from the ground up as the language for businessmen" and used "a very English-like grammar"1.

These languages are generally considered to reflect a 'procedural' paradigm of programming. In 1958, John McCarthy at M.I.T. began work on LISP which goes on to become one of the most important languages in the area of "Artificial Intelligence". LISP, which gets its name from LISt Processing, reflects a language model based on recursive functions. Another language, PROLOG, invented in the 70s, used a model based on 'logic programming' with predicate calculas

Use the above article to answer questions 10 –12

10. / What is the main idea of this passage?
A. / Computer programmers need to learn multiple languages so that they can meet end user requirements.
B. / Programming languages take many different forms and other programs help support these languages so that both human and computer can understand.
C. / Computer programming has been around for several years but remains unchanged.
D. / Computers are simple machines that work on everyday, easy to understand commands from the programmer.

PLEASE GO ON TO THE NEXT PAGE è

11. / Which of the following is not a logical inference from the passage?
A. / Machine code is composed of English like statements.
B. / Fortran and Cobol are considered to reflect a procedural paradigm of programming.
C. / A compiler allows human code to be converted into computer code
D. / Machine code has to be very specific and detailed.
12. / From information in the last section, what can we assume about a higher-level language?
A. / is more complicated than standard machine code
B. / is more computer friendly code
C. / is generally designed for specific purposes and uses
D. / is more expensive to update and maintain than lower level languages

PLEASE GO ON TO THE NEXT PAGE è

OPEN-RESPONSE QUESTION
Read all parts of the open-response question before you begin. Write your answers to the open-response question in the space provided on your Student Response Booklet. DO NOT WRITE ANY ANSWERS IN THIS TEST BOOKLET.

Check Boxes Or Option Buttons Or Combo Box

Computer programs are all around us each and everyday of our lives. Programmers make numerous decisions within the design process and one such decision can revolve around how selections can be made by the user of the program.
13. / A. Describe when a programmer should use check boxes, option buttons and combo boxes within a computer program.
B.  Explain a program in which the three design elements listed above(check boxes, option buttons, combo boxes) could be used and design the layout for the program so that it showcases the three main items (Check Box, Option Button, Combo Box)