





Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
This is introductory course for computer science. Its about basic concepts involving in computer programming, structure and working. Key points in this lecture handout are: Programming Language Basics, Values and Types, Computers and Computation, General-Purpose Machine, Universal Machine, Conditional Execution, Looping
Typology: Study notes
1 / 9
This page cannot be seen from the preview
Don't miss anything!






Today ...
Homework
Reading Assignment
A computer is a general-purpose machine (aka “universal machine”)
Tokens are the basic building blocks of programming languages
The keywords of a language are special tokens
The Python keywords (reserved words):
False class finally is return None continue for lambda try True def from nonlocal while and del global not with as elif if or yield assert else import pass break except in raise
Syntax specifies the legal statements
Semantics specifies the meaning of statements
Two main approaches for running programs
Compilers
Executable
Source Code (^) (a program)
input
output
Object Code
It’s easy to make mistakes when programming
Programmers do lots of debugging!
Develop code in small steps to avoid becoming overwhelmed by bugs
Types of bugs
Syntax errors
Runtime errors
Semantic errors
When a syntax or runtime error occurs, the Python interpreter