levo

Types of Programming Language

  • 5 subtopics
  • 13 things to know
  • Component 01

What Types of Programming Language covers

Types of Programming Language is examined on component 01 of OCR Computer Science, Computer systems. 64 recall questions across 5 subtopics.

Where it is assessed

Component 01

Computer systems, the whole of the first paper.

Check the OCR specification ↗

The 5 subtopics

Each one has its own page.

What you need to know

Answer each one before you reveal it.

Your recallNot started
Key term

Name three features you would expect to find in a procedural language.

Key term

What characterises a declarative paradigm, and how does it differ from an imperative one?

Key term

What characterises the logic paradigm?

Key term

In the Little Man Computer, what is the difference between BRA, BRZ and BRP?

Key term

A student uses BRP to loop while a counter is greater than zero, and finds the loop runs one time too many. Explain.

Key term

In immediate addressing, what does the operand actually mean?

Key term

In direct addressing, what does the operand actually mean?

Key term

What is an attribute?

Key term

Explain the difference between an attribute and a method, and between a class and an object.

Key term

What is inheritance?

Key term

Give an example of inheritance with a superclass and two subclasses.

Key term

What is polymorphism?

Key term

Name the four modes of addressing memory.

Take Types of Programming Language further

The same content, four other ways.

Commonly confused

Pairs that lose marks when they are blurred together.

  • A class vs An object

    A class: the template defining the attributes and methods that its instances will have. An object: one instance created from that template, with its own values.

  • An attribute vs A method

    An attribute: a data item belonging to an object, describing part of its state. A method: a procedure belonging to an object, defining something it can do.

  • Encapsulation vs Inheritance

    Encapsulation: keeping an object's data private and reachable only through its own procedures. Inheritance: defining a new class that takes on the members of an existing one and extends them.

Questions from this topic

Each one with the model answer underneath.

  1. 1

    What is a programming paradigm?

    Model answer

    A style or approach to programming - a whole way of thinking about how a program should be organised and what a program fundamentally is. It determines how the problem is broken down, how data and instructions are represented and how the flow of the program is controlled, rather than merely which keywords are typed.

  2. 2

    Why is there a need for more than one programming paradigm?

    Model answer

    Different kinds of problem have different natural shapes, and a paradigm that fits the shape of the problem produces code that is shorter, clearer and less likely to be wrong. Controlling a machine step by step suits a procedural approach; modelling a system of interacting real-world things suits objects; expressing a set of facts and rules and letting the machine search suits a declarative approach; responding to unpredictable user actions suits an event-driven one. Hardware and the size of projects have also changed over time, and paradigms developed to manage the growing complexity.

  3. 3

    What characterises the procedural paradigm?

    Model answer

    The program is a sequence of instructions telling the computer step by step what to do, in a stated order, using the three basic constructs of sequence, selection and iteration. Data is held in variables that the instructions read and change, and the instructions are grouped into procedures and functions that can be called from elsewhere. It is imperative: the code says how the task is to be carried out.

  4. 4

    Name three features you would expect to find in a procedural language.

    Model answer

    Variables and data types for storing values; the control constructs of sequence, selection and iteration; subroutines - procedures and functions - with parameters and local variables; and usually arrays and other structured data types. Examples of procedural languages include C, Pascal and Python used in a procedural style.

  5. 5

    What characterises the object-oriented paradigm?

    Model answer

    The program is organised as a set of objects that each bundle together their own data and the operations that act on it, and that interact by calling one another's methods. Objects are created from classes, which act as templates, and classes can inherit from other classes. Data is deliberately hidden inside objects rather than being globally available.

  6. 6

    What characterises a declarative paradigm, and how does it differ from an imperative one?

    Model answer

    A declarative program states what is wanted rather than how to obtain it, leaving the system to work out the steps. An imperative program - procedural or object-oriented - spells out the sequence of operations. A database query that asks for all customers in a given town is declarative; a loop that examines each record in turn and adds the matching ones to a list is imperative.

What is inside Levo

Six ways to work the same material.

1Closed book
2Open book
3Closed book

The 3-step method, run for you

Answer cold, learn it, then prove it stuck. Levo tracks the jump between your first attempt and your last.

Processors: Structure, Performance and Types
Input, Output and Storage
Systems Software
Applications Generation

Cram a whole paper in one sitting

Sort every topic into what you know and what you do not, then drill only the weak ones.

If it matches, the search .
succeedsfailsrestarts

Blank Blitz makes facts automatic

Rapid timed gap-fills on the terms and numbers you need to recall without thinking.

A0 + 0 gives 0.
B0 + 1 gives 1.
C1 + 1 gives 0 carry 1.

Build It gets the exam shape right

Assemble a full-mark answer from its marking points, in the order an examiner wants them.

A global variable means a variable reachable from anywhere in the program.
TrueFalse

Test It catches misconceptions

Spot the fault in a statement. The traps are the mistakes students actually make.

721941163128510

Brain Breaks between sessions

Short focus games to reset attention, so the next set lands better than the last.

Types of Programming Language revision questions

What does Types of Programming Language cover in OCR A-Level Computer Science?
5 subtopics: programming paradigms and procedural languages, assembly language and the little man computer, modes of addressing memory, object-oriented programming: classes and objects, attributes and methods, encapsulation and object-oriented programming: inheritance, polymorphism, advantages and disadvantages. Each one has its own page with questions and model answers.
How is Types of Programming Language organised?
By the OCR H446 specification, subtopic by subtopic, so it matches the order you are taught it in.

Every question in Types of Programming Language, on a schedule.

Attempt a question from memory, write the correct version, then attempt it again. Levo records the jump between your first attempt and your last, and brings each question back on the day you are due to forget it.

Or £46 a year, about £3.83 a month. Cancel anytime.