Examination: 30%
This assessment is graded out of 90 marks and weighted to be worth 30% of the module.
The examination will be theory based and will last 1.5 hours in duration. The assessor should devise an examination that allows the learner to demonstrate their competence and knowledge of the relevant learning outcomes and the theory behind them. The exam will conform to the following structure:
Section A –
10 short questions, answer all questions. Each short question is weighted at 3 marks each.
Section A is worth 30 marks out of 90 for the exam.
Questions should be based on LO 3: Demonstrate a knowledge of basic OOP constructs- examples are:
What is OOP, as distinct from Functional, procedural programming or scripting?
What is a class compared to an object?
What are the benefits of modularisation?
Why are namespaces a good idea?
Create a signed class diagram for a Dog, showing the identity, 2 attributes and one behaviour. Use pythonic variables.
Why might we make use of class libraries and packages?
How does a class method differ from a function?
What is the purpose of a constructor?
Explain encapsulation using an example
Explain abstraction using an example
Explain polymorphism using an example
Explain inheritance using an example
What does it mean to say "everything in Python is an object"? Can you give an example?
What is method overriding, and how is it used in inheritance?
What is a class attribute vs. an instance attribute? How do they behave differently?
What does self mean in a class method, and why is it required in Python?
What is the principle of DRY and how might inheritance be useful?
What is operator overloading?
What are magic or dunder methods in python?
Why might we use mutator and accessor methods?
What is composition in OOP, and how is it different from inheritance?
What is __str__() used for in Python classes, and how is it different from __repr__()?
What is the difference between a static method and a class method in Python?
What is super() and how is it used when dealing with inheritance?
What is duck typing in Python, and how does it relate to polymorphism?
Why is it helpful to use OOP when designing games, GUIs, or simulations?
How can unit testing be applied to object-oriented programs?
What is an interface in OOP, and does Python use them?
Can objects be passed as arguments to functions? What does that allow us to do?
Why is it helpful to follow naming conventions and coding style (like PEP8) in object-oriented Python code?
Section B –
Answer 1 long question out of a possible 2. Each question is worth 30 marks out of 90 for the exam.
Both questions to be based on LO 2: Understand the fundamental set of instructions involved in all programs and how to use them to construct programs to solve problems
Given this description and the suggested topics in the module descriptor, the exam is designed to offer some choices between code and theory. A suggested structure is to have one mainly theory question and one mainly code question, such as the following:
Theory topics
Generations of programming languages- what they are and impact on the programmer in using each
different forms of programming: functional, procedural, scripting, OOP
the similarities and differences, advantages and otherwise of interpreters and compilers
Big-O notation and algorithms
Code option
Create a class with different types of attributes, making use of operators, looping, conditional execution, calculation, importing.
Often this is based on common or uncommon shapes.
Section C –
Answer 1 long question out of a possible 2. Each question is worth 30 marks out of 90 for the exam.
Both questions to be based on LO 8: Explain ways to organise and structure data
Given this description and the suggested topics in the module descriptor, the exam is designed to offer some choices between code and theory. A suggested structure is to have one mainly theory question and one mainly code question, such as the following:
Theory topics
Modularisation and namespaces
Developing large software projects
Debug
Data structures- mutable and immutable
Code option
Create class(es) where you must make use of data structures, and determine how to code
Often this is based on two related classes, for example:
Player and sub-class Weaponised Player (inheritance) that can gather, store and use different inventory items
Card and Deck for classic card games (composition)
Bus baggage store with upper storage capacity, and baggage items with defined dimensions and weight
All instructions for the learner must be clearly outlined in the examination paper. Evidence for this assessment technique may be in a written or digital format (audio/video).