SLR 7 Flashcards
Types of programming language
What is meant by a paradigm in CS?
To describe an example of a way of doing things
What is a turing complete language?
A turing complete language can solve all the problems that a computer is able to solve
What is the point of programming paradigms?
Some paradigms are better at solving problems than others
What are the two categories that High-Level Languages fit into?
Imperative and Declarative
What is an imperative language?
A high-level language which consists of commands describing HOW a program operates
What is a declarative language?
A high-level language which focuses on WHAT a program should accomplish, not covered in any great detail
What is a procedural language?
A type of imperative programming paradigm where a program is built one or more subroutines
What is object-oriented programming?
A paradigm that identifies classes of objects which are closely linked to different methods
How do procedural languages lay out code?
A series of statements such as:
-Sequence
-Selection
-Iteration
This creates blocks of code using procedures and functions
What a mnemonics?
Simple sequences used in Assembly Languages
What makes up instructions?
The Opcode and Operand
Opcode - where something is being manipulated
Operand - what is being manipulated
How does a class work?
Has a class name, attributes and methods
What is instantiation?
The process of creating an object from a class template
What is the constructor method?
new ()
Used to create :D
What is inheritance?
Classes copying attributes and methods from other classes
What is encapsulation?
Bundling methods and restricting direct access to them (making them private)
What are the types of polymorphism in OOP?
Static and Dynamic
Static Polymorphism allows you to implement multiple methods of the same name with different parameters in the same class
Dynamic Polymorphism is sharing the same parameters but having different functionality