Computer Science

Description

Computational logic
Ana Rodrigues
Flashcards by Ana Rodrigues, updated more than 1 year ago
Ana Rodrigues
Created by Ana Rodrigues about 6 years ago
6
2

Resource summary

Question Answer
Defensive design It ensures that: 1. the number of errors or bugs is minimised 2.the program behaves as expected in spite of unexpected user actions 3.all possible errors that could occur are identified and allowed for
Validation : Presence check Presence checks ensure that data has been entered
Length check Length checks ensure that a specified number of characters have been entered
Range check Range checks ensure that an input falls within required range
Testing: Syntax errors They are grammatical mistakes in code, which could be caused by misspelling, (prnit instead of print) or by missing colons, semi-colons or brackets. They are very difficult to spot and stop the program from working.
Logic errors They cause unintended output because of the fault f the logic of the algorithm e.g. using an AND operator instead of OR operator.
Logic gates AND Gate: 1+1=1 1+0=0 0+1=0 0+0=0 Both have to be 1.
Logic gates OR Gate: 1+1=1 1+0=1 0+1=1 0+0=0 Only one has to be 1.
Logic gates NOT gate 1=0 0=1 It is the opposite.
Programing languages Machine language Processors only understand instructions written in 1s and 0s. Machine code is a low-level language.
Programing languages Assembly language Each instruction is directly equivalent to one in machine code. Words called mnemonics are used to replace the command represented as strings of 1s and 0s in machine code. This is a low level language.
Programming languages High-level language These are languages that resemble human languages. They use key words such as 'print', 'if', and 'then'.
Translators Compiler It translates the source code into a standalone, machine code program (object code) that can be executed by the processor.
Translators Interpreter It translates the high-level code line by line into machine code. It is needed each time the program is run.
Translators Assemblers They translate the mnemonics of assembly language into machine code instructions. Assembly language is very similar to machine code. This one assembly language instruction for each machine language instruction.
Show full summary Hide full summary

Similar

Computing Hardware - CPU and Memory
ollietablet123
A level Computing Quiz
Zacchaeus Snape
Types and Components of Computer Systems
Jess Peason
Input Devices
Jess Peason
SFDC App Builder 2
Parker Webb-Mitchell
Data Types
Jacob Sedore
Intake7 BIM L1
Stanley Chia
Output Devices
Jess Peason
Software Processes
Nurul Aiman Abdu
Design Patterns
Erica Solum
CCNA Answers – CCNA Exam
Abdul Demir