Unit 3 Flashcards
What is a proposition?
A statement
When evaluated propositions can result in 2 different results, what are they?
True or False
What is a boolean expression?
A statement that is either True of False.
What is a truth table?
A truth table is a mathematical table to show the output from inputs that are either true or false and are subject to a given rule.
What are the 7 different boolean rules?
AND, OR, XOR, NOT, NAND, NOR and XNOR
What is a bitmask?
A bitmask is used to carry out bitwise operations
Why would you use a bitmask?
Allows for a byte, nibble or a word to be turned on or off in a single operation.
Use the mask 00010000, to find the 4th most significant bit of 10010001.
00010000
What is data encryption?
Data encryption refers to the process that translates data into a
code that can only be accessed using the decryption key.
Using an XOR function encrypt 01011011, using 11001110 as the key.
10010101
Using an XOR function decrypt 10010101, using 11001110 as the key.
01011011
What is a compiler?
A program that converts an entire high-level language code program into machine code that can be executed by a computer.
What is an interpreter?
A program that converts high-level code program line by line into machine code.
What is an assembler?
An assembler is a program that converts assembly language into machine code.
What happens in lexical analysis?
Redundant parts of the code are removed.
Keywords, constants and identifiers are replaced by token.
A symbol table is created.