1/22
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai |
|---|
No analytics yet
Send a link to your students to track their progress
define constant
value that never changes during the execution of a program
what is the structure writing a constant in pseudocode
CONSTANT <identifier> = <value>
define variable
stores value that has been calculated and can be changed during the execution of the program
what is the structure of declaring a variable in pusedocode
DECLARE <identifier> : <data type>
how would you assign a value to an identifier
<identifier> ←- <value>
how would you write an input
INPUT <identifier>
how would you write an output
OUTPUT <identifier>
what are the arithmetic operations and what is the symbol
+ addition
- subtraction
(star) multiplication
/ division
^ exponent
what is integer division
finds the integer number before the decimal point after the division
how would you write an integer division
DIV (<identifier1> , <identifier2>)
what is modulus
finds the remainder that is left when a number is divided
how would you write a modulus
MOD (<identifier1> , <identifier2>)
what is the relational operations and what are the symbols
< less than
> more than
= equals to
<> not equal to
<= less than or equal to
>= more than or equal to
what are IF statements
used in a program when needs to make a decision and perform different actions depending on whether a condition is true or not
what is case
used when a program needs to perform different actions depending on the value of the variable.
what is the case structure
CASE OF <identifier>
<value1> : <statement>
<value2> : <statement>
OTHERWISE <statement>
ENDCASE
what are the iteration loops types
count controlled loops
pre condition loops
pre condition loops
what is the count controlled loops
number of iterations is already known
what is post condition loops
loop has the be executed at least once
what is pre condition loops
loop may not be executed at all
how would you write an iteration FOR
FOR <identifier> ←- <value1> TO <value2>
d <statement>
NEXT <identifier>
how would you write an iteration REPEAT
REPEAT
a <statement>
UNTIL <condition>
how would you write an interation WHILE
WHILE <condition> DO
fd <statement>
ENDWHILE