Docsity

CSP Study Guide.docx....CSP Study Guide.docx, Exams of Nursing

Toggle sidebar
bg1
CSP Study Guide
Unit 3 Test - correct answer
Algorithm - correct answer A precise sequence of
instructions for processes that can be executed by a computer
High Level Programming Language - correct answer A
programming language with many commands and features designed to make
common tasks easier to program.
Low Level Programming Language - correct answer A
programming language that captures only the most primitive operations available
to a machine
Iterate - correct answer To repeat in order to achieve,
or get closer to a desired goal
Selection - correct answer A generic term for a type of
programming statement that uses a Boolean condition to determine or select
whether or not to run a certain block of statements
Turtle Programming - correct answer A classic method
for learning programming with commands to control movement and drawings of an
on screen robot
Abstraction - correct answer A simplified version of
something more complex
Top Down Design - correct answer Problem solving
approach in which you break down a system to gain insight into the sub systems
that make it up
pf3
pf4
pf5
pf8
pf9
pfa

Partial preview of the text

Download CSP Study Guide.docx....CSP Study Guide.docx and more Exams Nursing in PDF only on Docsity!

CSP Study Guide

Unit 3 Test - correct answer Algorithm - correct answer A precise sequence of instructions for processes that can be executed by a computer High Level Programming Language - correct answer A programming language with many commands and features designed to make common tasks easier to program. Low Level Programming Language - correct answer A programming language that captures only the most primitive operations available to a machine Iterate - correct answer To repeat in order to achieve, or get closer to a desired goal Selection - correct answer A generic term for a type of programming statement that uses a Boolean condition to determine or select whether or not to run a certain block of statements Turtle Programming - correct answer A classic method for learning programming with commands to control movement and drawings of an on screen robot Abstraction - correct answer A simplified version of something more complex Top Down Design - correct answer Problem solving approach in which you break down a system to gain insight into the sub systems that make it up

API - correct answer A collection of commands made available to a programmer Documentation - correct answer A description of the behavior of a command , function, library, API, etc. Function - correct answer A named group of programming instructions Hexadecimal - correct answer A base 16- number system that uses sixteen distinct symbols 0-9 and A-F to represent from 0 to 15 Library - correct answer A collection of commands/functions, typically with a shared purpose Parameter - correct answer An extra piece of information passed to a function to customize it for a specific need Loop - correct answer Programming languages have some similarities and differences to the 'natural language you use in everyday speech. Select the two true statements about programming languages: Programming languages have some similarities and differences to the natural language you use in everyday speech. Select two true statements about programming languages: - correct answer Guess The robot is represented as a triangle, which is initially facing up, towards the top of the grid. The robot is moved according to the following instructions. Which of the following images shows the path and ending location of the robot that will result from executing the code above. The starting location of the robot is shown as a dotted triangle for cases where the robot does not start and end at the same location. - correct answer Image B Consider the following incorrect program, which is intended to move the robot around the perimeter of a grid, as indicated by the drawing below. The starting position and direction of the robot is indicated in the diagram.

Drawing a circle of any size at any point on the screen - correct answer Function Why are parameters useful while programming? - correct answer Parameters allow for more flexible, generalized behaviors in functions. Choose the two statements that are true about functions. - correct answer Functions in programming are named groupings of programming instructions. Meaningful function names help people better understand programs. Which of the following statements about writing functions and Top- Down Designs is NOT true? - correct answer Two programmers solving the same problem using Top-Down Design should arrive at identical programs. What is a function parameter? - correct answer A way to give input to a function that controls how the function runs. Unit 5 Lesson 1-5 Test - correct answer Event Listener - correct answer A command that can be set up to trigger a function when a particular type of event occurs on a particular UI element. Which of the following is FALSE about element ID's? - correct answer An element with a unique ID must always have an event handler associated with it. Local Variable - correct answer A variable with local scope is one that can only be seen, used and updated by any part of the code. its global scope is typically derived from the variable being declared outside of any function, object, or method. Event - correct answer An action that causes something to happen

Which of the following are actions a programmer could take when debugging a segment of code that would most likely lead to finding a problem and fixing it? (choose two) - correct answer Display the value of variables at various points during the program. Ask a friend or collaborator to look over the code segment to see if they are able to find any errors. Debugging - correct answer Finding and fixing problems in an algorithm or program. User Interface - correct answer The visual elements of a program through which a use controls or communications the application. Often abbreviated UI. UI elements - correct answer on screen objects, like buttons, images, text boxes, pull down menus. screens, etc. Expression - correct answer Any valid unit of code that resolves to a value. Global Variable - correct answer A variable whose scope is "global" to the program, it can be used and updated by any part of the code. Its global scope it typically derived from the variable being declared outside of any function, object, or method. Data Type - correct answer All values in a programming language have a "type" - such as a Number, boolean, or String that dictates how the computer will interpret it. For example 7+5 is interpreted differently from "7"+"5" Callback Function - correct answer A function specified as a part of an event listener; it is written by the programmer but called by the system as the result of an event trigger.

Event - driven program - correct answer A program designed to run blocks of code or functions in response to specified events What is displayed by the console.log statement after the following code segment executes?

  1. var a = 3
  2. var b = 6
  3. var c = 10
  4. a = b /a
  5. b = c - a
  6. c = b / a
  7. console.log(value is : +c) - correct answer value is: 4 Unit 5 Lesson 6-10 - correct answer Consider the following JavaScript code segment. If the above code segment is run, and "goodbye" is entered into the prompt, what will be displayed in the console? - correct answer Use that word on the SAT Which of the following statements about string in JavaScript is False? - correct answer Strings with numerical digits in them are invalid. A boolean expression is an expression that evaluated to which of the following? - correct answer True/False Consider the following segment given in pseudo code: What will be displayed if the grade is set to 70? - correct answer You passed!

Which of the following JavaScript statements will result in the following output being displayed to the console. - correct answer Hello! How are you? If statement - correct answer The common programming structure that implements "Conditional Statements" What is the output of the following JavaScript code segment? var str1 = 5 var str2 = 5 var result = str1 + str console.log - correct answer 55 Boolean Expression - correct answer In programming, an expression that evaluates to True or False In JavaScript you can find the number of characters in String by using .length. For example. In the above code segment is run, and "hello" is entered at the prompt, what will be displayed in the console? - correct answer I have never heard that before. What is the possible output when the following code segment executes? The ending position of the turtle is shown in each diagram. The starting position is shown as a white triangle in cases where the turtle starts and ends in different locations. - correct answer C Concatenate - correct answer (e.g. "Hello," + name) Consider the following JavaScript code segment. Something is wrong with the logic in the program above. For which values of time will the greeting "good morning" be displayed? - correct answer There is no value of time that will result in "good morning" being displayed

they wrote runs without error, but unfortunately it does not work as well as intended. What is the problem? Consider the list of values below and choose two that if assigned to weight will result in the incorrect message being displayed as the response? - correct answer 125 & 200 Consider the following flow chart showing a process for program execution. Given that a = 5 and b = 10. What will be displayed by the program? - correct answer 10 Assume that a variable temperature is assigned like this: var temperature = 30 Choose the 2 Boolean expressions that evaluate to FALSE. - correct answer (temperature == 0) || (temperature > 32) (temperature <0) || (temperature >32) Consider the code segment below given in pseudo code. Assuming that variables a, b, and c already have numeric values assigned to them, what is the expected output of this code segment? - correct answer The code will display the largest of all three values.