1/78
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
Flowchart
a visual diagram of the sequence of operations in a computer program
Algorithm
a step-by-step procedure for solving a problem, written more like everyday spoken language than like coding
IPO/IPO Chart
Stands for (Input/Process/Output). A chart or table used to
Processing Item
an intermediate value (neither input nor output) that an algorithm uses when processing the input into the output
Pseudocode
Shorthand notation for programming which uses a combination of informal programming structures and verbal descriptions of code.
Control Structure
one or more programming language statements that control the flow of a computer program. SEQUENCE, SELECTION, REPETITION
Selection
A generic term for a type of programming statement (usually an if-statement) that uses a Boolean condition to determine, or select, whether or not to run a certain block of statements.
Flowchart symbols
Oval - Begin or end
Rectangle - Process
Parallelogram - Input/Output
Diamond - Decision
Arrow - Direction of Flow
Circle- Used to connect separated charts on the same page
Pentagon- Used to connect separated charts on different pages
While Loop
a programming construct used to repeat a set of commands (loop) as long as a boolean condition (while) is true. This is a CONDITION based construct.
For Loop
A typical looping construct designed to make it easy to repeat a section of code using a counter variable. The for loop combines the creation of a variable, a boolean looping condition, and an update to the variable in one statement. This is a COUNT based control structure.
Program
Provide a computer or other machine with coded instructions for the automatic performance of a particular task.
Software
written programs or procedures or rules and associated documentation pertaining to the operation of a computer system and that are stored in read/write memory. Cannot be physically touched.
Hardware
The machines, wiring, and other physical components of a computer or other electronic system. Can be physically touched.
Machine Language
The way a computer understands instructions at the base level. Binary code made up of 0s and 1s; usually this is data converted from a high-level language by a compiler. Often used as a synonym for low-level programming language.
Assembly Language
Programming language that has the same structure and set of commands as machine languages but allows programmers to use symbolic representations of numeric machine code. These were the early versions of software languages used by programmers, not commonly used anymore.
High-Level Language
A programming language like Python or C# that is designed to be easy for humans to read and write.
Source Code
A text listing of commands to be compiled or assembled into an executable computer program. Source code is what you type into C#.
RAM
Random Access Memory; temporary memory. RAM is expandable, and resides on the motherboard. This is a VOLATILE memory storage area.
Assembler
A program that translates an assembly-language program into machine language/code
Compiler
A program that translates code in a high-level language (such as Java) to machine instructions (such as binary).
Interpreter
Converts a program written in a higher level language into a lower level language and executes it, beginning execution before converting the entire program.
Syntax
states the rules for using words, phrases, clauses and punctuation. Correct syntax examples include word choice, matching number and tense, and placing words and phrases in the right order.
Syntax Error
a character or string incorrectly placed in a command or instruction that causes a failure in execution. (examples: misspelling a word, incorrect cases, forgetting a semicolon)
Logic Error
program runs but does the wrong thing
Compilation Error
when a program does not compile because of syntax errors or lexical errors
Runtime Error
An error that does not occur until the program has started to execute but that prevents the program from continuing.
Variable Declaration Statement
the form that introduces a new variable name and its data type in a program (int x;)
Variable Initialization
Assigning a value to a variable at declaration is called ( int x ==2;)
Variable
A symbol used to represent a quantity that can change
Naming Convention
a way of capitalizing letters to define if an item is a method, variable, or constant. For example PascalCase for methods and camelCase for variables.
What naming convention is used for a variable?
camelCaseIsUsed
What naming convention is used for a method?
PascalCaseIsUsed
What naming convention is used for a constant?
ALL_CAPS_WITH_UNDERSCORE
Variable Assignment
an instruction that sets a value to a variable that already exists within the program
Calculations
a problem using numbers (or variables with assigned numbers) and operators (add, subtract, multiply, divide, etc)
Data types: String
Allows any combination of letters, numbers and spaces. In C# all inputs come in as strings unless otherwise parsed.
Data types: Integer
Stores positive or negative whole numbers
Data Types: Double
stores positive or negative whole numbers and decimals
Named Constant
is an identifier that represents a permanent value. The value of a variable may change during the execution of a program; but a Named Constant (or just Constant) represents permanent data that never changes. For ex: π is always 3.14...)
Hand Tracing
is a method for hand simulating the execution of your code in order to manually verify that it works correctly before you compile it. Draw a table with each variable in the program shown at the top of the column.
Comments
a way of making notations within your code to let other programmers know what is going on. Use "//" to make a comment in C#.
Type of Method: Void
this is a type of method that does not return anything to the main method. It can display things on the screen and produce outputs, but will not return any values to another method.
Type of Method: Value Returning
This type of method returns a value to the method from which it was called. The value returned can be any type, such as a string or integer or double.
Passing by Value
refers to the process of passing a copy of a variable's value to another procedure/ method
Passing by Reference
refers to the process of passing a variable's address to a procedure so that the value in the variable can be changed. Changes the original instead of making a copy to change.
Calling a Method
makes a method call that invokes/begins the called method
Defining a Method
The entire portion of a method within the code. Includes everything from the method header and everything within { }
Method Body
Everything between {} of a method
Method Header
the first line of the method and contains information about how other methods can interact with it.
For example: "string void UpdateNumber(int x, int y)"
Method Signature
The name of a method, along with its number and type of parameters.
For example: "UpdateNumber(int x, int y)"
Method Overloading
The ability to define two or more different methods with the same name but different method signatures. (Like having two humans with the same name, they may have the same name, but they are different methods)
Variable Scope
dictates what portions of the code can "see" or use a variable, typically derived from where the variable was first created.
Parameter
the variables within a method header/method signature
Argument
variables that are sent to the method, found within the line of code that calls the method
Passing Arguments
The act of sending arguments (variables) to a method.
Return Statement
causes a value to be sent from the called method back to the calling method
Single Alternative Decision Structure
provides only one alternative path of execution (ex. an "if" statement)
Dual Alternative Decision Structure
has two possible paths of execution, one path is taken if the condition is true and the other path is taken if the condition is false (ex. "if/else" statement)
Multiple Alternative Decision Structure
Allows you to test the value of a variable or an expression and then use that value to determine which statement or set of statements to execute. (ex. Case/Switch structure, or a multiple If/Else statement)
Relational Operators
Used to compare two values. Operators include =,<,>,<=,>=,<> (ex. also includes nested if statements)
Logical Operators
&& [and]
|| [or]
! [not]
Truth Table
A table used as a convenient method for organizing the truth values of statements
Truth Table for AND
Reads left to right. With an AND statement if even one is false then statement is false.
Truth Table for OR
Reads left to right. With an OR statement, if even one is true then statement is true.
What kind of chart is this?
IPO Chart
What kind of chart is this?
Flowchart
What is the output of this code:
int x = 5;
int y = 10;
while (x < 100)
{
x = x + y;
}
Console.WriteLine(x);
105
What is the output of this code:
int input = 0;
int sum = 0;
Console.WriteLine("Enter Number");
input = int.Parse(Console.ReadLine());
while(input != 999)
{
sum += input;
}
Console.WriteLine(sum);
infinite loop; no output
Sentinel Value
a preselected value that stops the execution of a program or loop (ex: "Type -1 to exit")
Boolean Operators
AND, OR, and NOT operators used in a query.
Short Circuit Techniques
The program reading an operator left to right. Purposefully putting the most volatile variable on the left of the operation to help the program evaluate it faster.
Counter-Controlled Loop
a loop whose processing is controlled by a counter; the loop body will be processed a precise number of times ("For" loop)
Condition-Controlled Loop
uses a true/false condition to control the number of times that it repeats. ("while" loops)
Pre-Test Loop
A loop that tests before deciding whether the execute its body. for and while are both pre-test loops.
Post-Test Loop
A loop that executes the body, then tests for the exit condition. An example of this would be a "do/while" loop
Priming Read or Priming the Loop
the input instruction that appears above the loop that it controls; used to get the first input item from the user
Update Read or Update the Loop
allows the user to update the value that controls the loop's condition. appears within the loop, usually at the end of the loop body
Infinite Loop
A loop in which the terminating condition is never satisfied. Usually because there is not an update read.
Nested Loop
A loop inside the body of another loop.