Programming in Python

Python is a general-purpose scripting language that is both rich in features and simple enough to learn as the first programming language. Over the past years, Python has grown in popularity, consistently holding a top 3 spot in most reputable ranking exercises. The interest is fueled by the wealth of learning resources, tools, and libraries available mostly for free.

After going through the fundamentals and the tools required, this unit will explore both the language syntax and common libraries that facilitate the programmer’s tasks. Concepts such as data types, complex variables, functions, control structures and documentation will be covered. Several libraries will be used for a variety of applications including automating common tasks, using files, connecting to web servers, and testing the code developed.

Although the unit assumes some familiarity with another programming language and a basic understanding of how the websites are written and deployed, it will still cover the basics. The approach taken will be a combination of lectures and in-class practical sessions where participants can work at their own pace with tasks matching the different skill levels. Read more 

Learning Outcomes:

1. Knowledge & Understanding:

By the end of the Unit the student will be able to:

– Distinguish between the different programming paradigms;
– Identify the different Python data types;
– Identify the different Python control structures;
– Effectively use Python functions, arguments and return values;
– Grasp the basics of interacting with the Operating System;
– Recognize the need for exception handling;
– Recognize the need for testing;
– Explain how technologies enable the World Wide Web;
– Identify basic web page code elements.

2. Skills:

By the end of the Unit the student will be able to:

– Install and set up Python environments;
– Use an IDE for debugging and troubleshooting;
– Solve simple tasks using scripts;
– Contrast different approaches to the same problem;
– Read from and write to files programmatically;
– Install and use third-party libraries;
– Connect and retrieve information from a web server;
– Handle runtime exceptions gracefully;
– Implement test cases for automated testing.

Main Text/s and any supplementary readings:

Learn Python, Break Python – A Beginner’s Guide to Programming

Automate the Boring Stuff with Python

Learn Python By Example

ADDITIONAL NOTES Pre-requisite Knowledge, Skills and Competences: Basic programming skills (in any language) and understanding of simple web technologies.