Duration
Nil
Prerequisites
Nil
Corequisites
Nil
Aims and learning outcomes
The purpose of the module is to introduce learners to the general principles of software development process, basic syntax of a suitable programming language, control structures (sequential, selection, and repetition), and programming concepts such as variables, functions, modules, and file processing.
Students who successfully complete this unit should be able to:
- Explain the basic conceptual elements of the chosen program development environment
- Use the basic syntax features of the chosen language to write simple instructions
- Create, debug and test software applications written in the chosen language
- Implement the concepts of sequence, selection, and repetition control structures in the chosen language
- Use complex logical structures in developing algorithms to solve problems
- Acquire a broad knowledge in the chosen programming language
- Apply theoretic concepts, in a chosen stream, to a range of situations
Unit information
Content
Lecture
- Introduction to Computing, Overview of Software
- Development Process and Diagrams
- Introduction to Python Programming
- Python Types, Variable, Simple I/O, Strings and Collections
- Planning a Procedure Using Pseudocode
- Selection: If-elif-else
- Repetition: While Loop, For Loop
- Python: User defined functions
- Python Module
- Python Files I/O
- Overview of Other Programming Languages
Tutorial/Lab
- Pseudocode, algorithms and diagrams
- Features of Python, Python IDE: Interactive Mode, Python IDE: Development Mode, Creating simple code for displaying a sentence
- Variables, Input() Function, Useful Mathematical Operators, Python Assignment Statement, Swap Variables, Numbers, Strings, Tuples, Lists, Sets, Dictionaries
- If-statement, If-else statement, If-elif-else statement, Nested if-else statement, Generate random numbers
- While Loop, Infinite Loop, While-else statement, While loop with if-else and break statement, For Loop, For Loop and range() function, Random access with len() function, Iterating over type, list, dictionary
- Call a function, Function without arguments, Function with arguments, The return statement in function, Default argument values, Arbitrary Argument Lists
- Creating a module, Importing a module, From..import statement, Executing modules as scripts, Modules Path, Standard Module
- Raw input Function, Input Function, Opening and Closing Files, The file Object Attributes, Reading and Writing Files, Renaming and Deleting Files, Directories in Python
- Overview of Other Programming Languages