Indicate the answer choice that best completes the statement or answers the question. Enter the appropriate word(s) to complete the statement.

Similar documents
PLD Semester Exam Study Guide Dec. 2018


Computer Programming C++ (wg) CCOs

Repetition Structures

Condition-Controlled Loop. Condition-Controlled Loop. If Statement. Various Forms. Conditional-Controlled Loop. Loop Caution.

A Beginner s Guide to Programming Logic, Introductory. Chapter 5 Looping

Topics. Introduction to Repetition Structures Often have to write code that performs the same task multiple times. Controlled Loop

Introduction to Computer Science Midterm 3 Fall, Points


An Introduction to Programming with C++ Sixth Edition. Chapter 7 The Repetition Structure

Glossary. For Introduction to Programming Using Python By Y. Daniel Liang

Assoc. Prof. Dr. Marenglen Biba. (C) 2010 Pearson Education, Inc. All rights reserved.

Chapter 5: Control Structures II (Repetition) Objectives (cont d.) Objectives. while Looping (Repetition) Structure. Why Is Repetition Needed?

4.1 COMPUTATIONAL THINKING AND PROBLEM-SOLVING


Lecture 7 Tao Wang 1

Computer Science 4U Unit 1. Programming Concepts and Skills Algorithms

Internet & World Wide Web How to Program, 5/e by Pearson Education, Inc. All Rights Reserved.

Programming Languages Third Edition. Chapter 9 Control I Expressions and Statements

Computer Programming I - Unit 5 Lecture page 1 of 14

L o o p s. for(initializing expression; control expression; step expression) { one or more statements }

Repetition and Loop Statements Chapter 5

C++ Programming: From Problem Analysis to Program Design, Fourth Edition. Chapter 5: Control Structures II (Repetition)

More on control structures

IUSE Knowledge Test. 1. Demographic Questions. IUSE Knowledge Test. 2. Computational Thinking Knowledge Test

Euclid s algorithm, 133

Programming Logic and Design Sixth Edition

Control Flow. COMS W1007 Introduction to Computer Science. Christopher Conway 3 June 2003

CIS 3260 Intro to Programming in C#

Introduction. C provides two styles of flow control:

12 Abstract Data Types

19 Much that I bound, I could not free; Much that I freed returned to me. Lee Wilson Dodd

Introduction to C Final Review Chapters 1-6 & 13

Chapter 3. More Flow of Control. Copyright 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley

Repeating Instructions. C# Programming: From Problem Analysis to Program Design 2nd Edition. David McDonald, Ph.D. Director of Emerging Technologies

Developing Algorithms

*Starting Out with C++: From Control Structures through Objects, 7/E* by *Tony Gaddis* COMPUTER PROGRAMMING LECTURE 05 LOOPS IMRAN IHSAN

Programming for Engineers Iteration

5.1. Chapter 5: The Increment and Decrement Operators. The Increment and Decrement Operators. Looping. ++ is the increment operator.

B.V. Patel Institute of Business Management, Computer & Information Technology, Uka Tarsadia University

Programming Fundamentals

CS110D: PROGRAMMING LANGUAGE I

C++ Programming: From Problem Analysis to Program Design, Third Edition

Chapter 8 Algorithms 1

And Parallelism. Parallelism in Prolog. OR Parallelism

Formal Specification and Verification

Chapter 6 Repetition. 6.1 Do Loops 6.2 For...Next Loops 6.3 List Boxes and Loops

CPSC 3740 Programming Languages University of Lethbridge. Control Structures

Laboratory 5: Implementing Loops and Loop Control Strategies

REPETITION CONTROL STRUCTURE LOGO

Lecture 6 Sorting and Searching

Sorting. Introduction. Classification

To become familiar with array manipulation, searching, and sorting.

Variable A variable is a value that can change during the execution of a program.

Self-test Programming Fundamentals

Program Development. Chapter 3: Program Statements. Program Statements. Requirements. Java Software Solutions for AP* Computer Science A 2nd Edition

Chapter 6 Repetition

Software Engineering using Formal Methods

Chapter 3: Program Statements

Programming for the Web with PHP

Conditionals and Loops

STUDENT LESSON A12 Iterations

High Institute of Computer Science & Information Technology Term : 1 st. El-Shorouk Academy Acad. Year : 2013 / Year : 2 nd

ECE 122. Engineering Problem Solving with Java

Java How to Program, 9/e. Copyright by Pearson Education, Inc. All Rights Reserved.

Lecture 2 Arrays, Searching and Sorting (Arrays, multi-dimensional Arrays)

In this chapter you ll learn:

To Do Panel. Contents

Computer Science Department Carlos III University of Madrid Leganés (Spain) David Griol Barres

DEPARTMENT OF COMPUTER AND MATHEMATICAL SCIENCES UNIVERSITI TEKNOLOGI MARA CAWANGAN PULAU PINANG

COMP 202 Java in one week

A Short Summary of Javali

Chapter 7 Control I Expressions and Statements

Software Engineering using Formal Methods

TABLE OF CONTENTS 2 CHAPTER 1 3 CHAPTER 2 4 CHAPTER 3 5 CHAPTER 4. Algorithm Design & Problem Solving. Data Representation.

CS164: Midterm I. Fall 2003

Volume II, Section 5 Table of Contents

Chapter 5. Repetition. Contents. Introduction. Three Types of Program Control. Two Types of Repetition. Three Syntax Structures for Looping in C++

Chapter 8 Statement-Level Control Structures

A Beginner s Guide to Programming Logic, Introductory. Chapter 6 Arrays

Introduction to Computer Programming for Non-Majors

COMSC-051 Java Programming Part 1. Part-Time Instructor: Joenil Mistal

Flow Control. CSC215 Lecture

Chapter 3: The Efficiency of Algorithms

Algorithm Discovery and Design

In Fig. 3.5 and Fig. 3.7, we include some completely blank lines in the pseudocode for readability. programs into their various phases.

Outline. Parts 1 to 3 introduce and sketch out the ideas of OOP. Part 5 deals with these ideas in closer detail.

Arrays and Lists Review CSC 123 Fall 2018 Howard Rosenthal

Here we will only consider the problem of searching among the elements of an array. Intro Programming in C++

Searching. 11. Searching

CSE030 Fall 2012 Final Exam Friday, December 14, PM

Angela Z: A Language that facilitate the Matrix wise operations Language Reference Manual

Announcements. Lab Friday, 1-2:30 and 3-4:30 in Boot your laptop and start Forte, if you brought your laptop

Introduction to Visual Basic and Visual C++ Arithmetic Expression. Arithmetic Expression. Using Arithmetic Expression. Lesson 4.

Problem Solving and Algorithms

About this exam review

Microsoft Visual Basic 2005: Reloaded

\n is used in a string to indicate the newline character. An expression produces data. The simplest expression

Review Chapters 1 to 4. Instructor: Scott Kristjanson CMPT 125/125 SFU Burnaby, Fall 2013

Final Examination Semester 3 / Year 2010

Transcription:

1. C#, C++, C, and Java use the symbol as the logical OR operator. a. $ b. % c. ^ d. 2. errors are relatively easy to locate and correct because the compiler or interpreter you use highlights every error. a. Input b. Logic c. Syntax d. Process 3. Programmers use the term to describe programs that are well designed and easy to understand and maintain. a. industrial b. intractable c. well behaved d. elegant 4. A(n) is another name for a subscript. a. index b. place holder c. pointer d. sequence 5. When using a bubble sort to sort a 10-element array, on the fourth pass through the array list you detect that no swap has occurred. This indicates. a. you must make one more pass through the array b. you must make a total of 10 passes through the array c. all elements in the array are already in the correct order d. the elements in the array were badly out of order 6. The NOT operator is a operator, meaning it takes only one operand. 7. When creating a truth table, you must determine how many possible Boolean value combinations exist for the conditions. If there are two conditions, combinations will exist. a. two b. four c. eight d. 16 8. Because they enable you to locate a particular record directly (without reading all of the preceding records), random access files are also called files. a. sequential access b. pointed access c. indirect access d. direct access 9. You can perform a by making comparisons using either the lowest or highest value in a range of values. a. logic check b. trivial expression c. range check d. nested if 10. When mathematicians use a two-dimensional array, they often call it a or a table. Copyright Cengage Learning. Powered by Cognero. Page 1

a. square b. vector c. grid d. matrix 11. A bubble sort is sometimes called a. a. compare sort b. dropping sort c. sinking sort d. pair sort 12. if-else examples can also be called because they contain the action taken when the tested condition is true and the action taken when it is false. a. do loops b. repetition c. dual-alternative selections d. single-alternative selections 13. In a truth table, the expression is false. a. false OR false b. false OR true c. true OR true d. true OR false 14. Use a counter or a(n) to control a loop s repetitions. a. sentinel variable b. end value c. end statement d. sentinel value 15. Programmers say that variables and constants declared within a module are only within that module. a. in reference b. abstracted c. in scope d. out of scope 16. A allows users to interact with a program in a graphical environment. a. command line b. GCI c. CGI d. GUI 17. When businesses store data items on computer systems, they are often stored in a framework called the data that describes the relationships between data components. 18. Whole number variables are known as variables. 19. The amount by which a for loop control variable changes is often called a value. a. group b. key c. step d. sentinel 20. A(n) is a program that you use to create simple text files. a. text editor b. IDE c. GUI d. GDE Copyright Cengage Learning. Powered by Cognero. Page 2

21. One advantage to using a named constant is that the statement becomes. a. self-referencing b. self-mitigating c. self-perpetuating d. self-documenting 22. tasks include any steps you must perform at the beginning of a program to get ready for the rest of the program. 23. When the records in a file are sorted in order from lowest to highest values, the records are in order. a. descending b. merged c. bubble d. ascending 24. A(n) is any numeric variable you use to count the number of times an event has occurred. a. counter b. index c. key d. accumulator 25. A(n) is a small unit of storage that, for example, holds only one character in a simple text file. 26. When you use an index, you can store records on a storage device. a. sequential-access b. linear-access c. random-access d. uniform-access 27. The file holds temporary data that is used to update the master file. a. directory b. database c. merge d. transaction 28. Programmers say the statements that are contained in a module have been. a. embedded b. modularized c. encapsulated d. decomposed 29. Pseudocode uses the end-structure statement to clearly show where the structure ends. a. end b. endstructure c. endif d. endloop 30. Named hold values that do not change during a program s execution. a. objects b. items c. constants d. variables Copyright Cengage Learning. Powered by Cognero. Page 3

31. Usually, when you create nested loops, each loop has its own. a. sentinel value b. loop control variable c. entrance condition d. goto statement 32. The case structure is a variation of the structure. a. selection b. while c. sequence d. do Match each term with a statement below. a. Reliability b. Declaration c. Echoing input d. String variable e. Identifier f. Prompt g. Variables h. Data dictionary i. Numeric variable j. Type-safety 33. Named memory locations whose contents can vary or differ over time 34. The act of repeating input back to a user either in a subsequent prompt or in output 35. A list of every variable name used in a program, along with its type, size, and description 36. A program component s name 37. A statement that provides a data type and an identifier for a variable 38. The feature of programming languages that prevents assigning values of an incorrect data type 39. Can hold digits and have mathematical operations performed on it 40. The feature of programs that assures you a module has been tested and proven to function correctly 41. Can hold text, such as letters of the alphabet, and other special characters, such as punctuation marks 42. A message that is displayed on a monitor to ask the user for a response and perhaps explain how that response should be formatted 43. is processing that involves performing the same tasks with many records, one after the other. a. Online processing b. Volume processing c. Batch processing d. Standard processing Copyright Cengage Learning. Powered by Cognero. Page 4

44. A loop within another loop is known as a(n) loop. a. infinite b. hidden c. indefinite d. nested 45. In a, the loop body executes at least one time because the loop control variable is not tested until after one iteration. a. posttest loop b. loop control c. pretest loop d. nested loop 46. Before a programmer plans the logic of the program, he or she must. a. test the program b. understand the problem c. write the program code d. maintain the program 47. The process of naming program variables and assigning a type to them is called variables. a. identifying b. proclaiming c. initializing d. declaring 48. A(n) is a location on your computer screen where you type text entries to communicate with the computer s operating system. a. GCI b. command line c. communication line d. input line 49. The first step in a while loop is typically to. a. execute the body of the loop b. initialize the loop control variable c. increment the loop control variable d. compare the loop control variable to a constant value 50. can ensure that a value is the correct data type or that it falls within an acceptable range. 51. Every array has a(n) size. a. infinite b. finite c. constant d. variable 52. In its simplest form, creating a(n) list involves creating one extra field in every record of stored data. 53. When you search through a list from one end to the other, you are performing a. Copyright Cengage Learning. Powered by Cognero. Page 5

a. quadratic search b. single lookup c. linear search d. binary search 54. A error results when you use a syntactically correct statement but use the wrong one for the current context. a. programming b. semantic c. logical d. syntax 55. Programmers employ the acronym to mean that if your input is incorrect, your output is worthless. a. IIOW b. IBOW c. GIGO d. GIGS 56. Adding to a variable is called the variable. Match each term with a statement below. a. linear search b. out of bounds c. flag d. parallel arrays e. array f. element g. for loop h. named constant i. binary search j. populating the array 57. Each separate item in an array 58. A series of values in computer memory 59. With a(n), you perform an action or task, and then you perform the next action, in order. a. loop sequence b. ordered structure c. sequence structure d. sequence problem 60. Both operands in a comparison expression must be the same. a. value b. name c. length d. data type Copyright Cengage Learning. Powered by Cognero. Page 6