CSP1150 Lecture 1 Introduction to Programming - Part A
CSP1150 Lecture 1 Introduction to Programming - Part A
Programming Principles
Lecture 1: Introduction to Programming
This Lecture
• Establishing a context
– Approach to the unit
– What is programming?
– Program implementation and source code
• Program design
– Pseudocode and flowcharts
• Getting started
– Introduction to Python
– A simple program
– Variables, comments and concatenation
Textbook
• Any errors in your syntax will prevent the code from running
prunt('Hello world!') Python
• RoboTest.robo
FORWARD(1) Robo
TURN(LEFT)
FORWARD(1)
TURN(LEFT)
FORWARD(1)
TURN(LEFT)
FORWARD(1)
TURN(LEFT)
• EndOfRoom.robo
Robo
Program Design
Program Design
Symbol Meaning
Display result
Name
length >
15?
True False
Display name
PHP
from row
$results = $db->query("SELECT * FROM users");
You should know exactly what you are building, and how,
before you start writing any code
Writing Good Code…
xkcd.com
A Brief History of
Programming Languages
Early High-Level Languages