BBM 101 - Introduction to Programming I
Fall 2018

Drawing of Analytical Engine. Image: University of Cambridge
Course Information
Course Description
This course serves as an introduction to the fundamentals of computer science and programming. It aims to help students with little or no programming experience to gain necessary skills to work with abstract notions for solving computational problems. The course is structured around basic topics such as control flow, functions, lists, input and output, simple data structures (sets, dictionaries), testing and debugging, recursion and pointers. The class will use the Python and C programming languages as a medium to provide a basic understanding of basic concepts in computer science, and the students will gain hand-on experience via a set of programming assignments supplied in the complementary BBM 103 Introduction to Programming Practicum.
Time and Location
BBM 101
Section 1: Wednesday at 13:00-14:50, Thursday at 09:00-09:50 in Clasroom D1
Section 2: Wednesday at 13:00-15:50 in Clasroom D2
Section 3: Wednesday at 13:00-15:50 in Clasroom D3
BBM 103
Lab Section 1: Thursday at 10:00-11:50 in Comp. Lab
Lab Section 2: Friday at 13:00-14:50 in Comp. Lab
Lab Section 3: Friday at 15:00-16:50 in Comp. Lab
Instructors

Aykut Erdem(Section 1)
aykut@cs.hacettepe.edu.trOffice Hours:
Thursday
15:00-16:00
Office 111
http://web.cs.hacettepe.edu.tr/~aykut

Fuat Akal (Section 2)
akal@cs.hacettepe.edu.trOffice Hours:
Open door
Office 202
http://yunus.hacettepe.edu.tr/~akal/

Aydın Kaya(Section 3)
aydinkaya@cs.hacettepe.edu.trOffice Hours:
Thursday
15:00-16:00
D1 or D2
http://web.cs.hacettepe.edu.tr/~aydinkaya
Teaching Assistants

Ahmet Selman Bozkır
selman@cs.hacettepe.edu.trOffice Hours:
Office 222
Bahar Gezici
bahargezici@cs.hacettepe.edu.trOffice Hours:
Tuesday
14:00-15:00
Research Lab. 1

Feyza Nur Kılıcaslan
feyzanur@cs.hacettepe.edu.trOffice Hours:
Research Lab. 1

Nebi Yilmaz
yilmaz@cs.hacettepe.edu.trOffice Hours:
Research Lab. 1
Communication
The course webpage will be updated regularly throughout the semester with lecture notes, programming and reading assignments and important deadlines. All other course related communications will be carried out through Piazza. Please enroll the corresponding class pages by following the links https://piazza.com/hacettepe.edu.tr/fall2018/bbm101 and https://piazza.com/configure-classes/fall2018/bbm103.
Pre-requisites
Students are not expected to have any prior programming experience.
Course Requirements and Grading
Grading for BBM 101 will be based on
- two midterm exams (25%+30%),
- a final exam (40%), and
- class participation (5%).
- a set of quizzes (25%),
- five programming assignments (5+4*15=65%) (done individually), and
- class participation (10%)
Policies
All work on assignments must be done individually unless stated otherwise. You are encouraged to discuss with your classmates about the given assignments, but these discussions should be carried out in an abstract way. That is, discussions related to a particular solution to a specific problem (either in actual code or in the pseudocode) will not be tolerated.
In short, turning in someone else’s work, in whole or in part, as your own will be considered as a violation of academic integrity. Please note that the former condition also holds for the material found on the web as everything on the web has been written by someone else.
Reference Books
CS for All, Christine Alvarado, Zachary Dodds, Geoff Kuenning, Ran Libeskind-Hadas, 2013
Introduction to Computation and Programming Using Python, Second Edition, John V. Guttag, MIT Press, August 2016
The Python Tutorial (available from the Python website)
Think Python, 2nd edition, Allen B. Downey (freely available online) (interactive version)
C How to Program, 6th Edition, Paul Deitel & Harvey Deitel , Prentice Hall, 2010
The C Programming Language, 2nd Edition, Brian Kernighan and Dennis Ritchie, Prentice Hall, 1988
Practical C Programming 3rd Edition, Steve Oualline, O'Reilly Media, 1997
Schedule
Week | Date | Topic | Notes |
---|---|---|---|
1 | Oct 10 | Course Introduction, What is computation? [slides] Week 1 Lab Handout [Using Piazza, BBM103 Grading Policy] | Reading: Guttag 1, Downey 1 Video: The birth of the computer, George Dyson |
2 | Oct 17 | Computers [slides] Week 2 Lab Handouts [Github Classroom, Linux Commands | PA1 out Reading: Alvarado et al. 4 (excluding 4.5-3-4.5.4) HMMM Simulator |
3 | Oct 24 | Introduction to Python [slides] Week 3 Lab Handouts [Programming in HMMM] | Reading: Guttag 2.1, Downey 5.1-5.3 |
4 | Oct 31 | Control flow, Functions [slides] Week 4 Lab Handouts [Programming Topics] | PA1 due Reading: Guttag 2.2-2.4, 3, 4.1-4.2, 4.4, Downey 3, 5.4-5.7 |
5 | Nov 7 | Midterm exam 1 Week 5 Lab Handout [Programming Topics] | PA2 out |
6 | Nov 14 | Collections, File I/O [slides] Week 6 Lab Handout [Exercises] | Reading: Guttag 4.6, 5.1-5.3, 5.5, Downey 10-12, 14.1-14.4, 14.11 |
7 | Nov 21 | Recursion [slides] Week 7 Lab Handout [ Programming Topics] |
PA2 due (23.11.2018)[Assignment2] Reading: Guttag 4.3, Downey 5.8-5.10, 6.5 |
8 | Nov 28 | Sorting, List Comprehension, Visualization [slides] Week 8 Lab Handout [Programming Topics] [Exercise] |
PA3 out Reading: Guttag 5.3.2, 10.2, 11 RiseSetData .zip |
9 | Dec 5 | Testing and Debugging [slides] Week 9 Lab Handout [Programming Topics] [Exercise] |
Reading: Guttag 6, 7, Downey Debugging sections of each chapter, Appendix A RiseSetData.zip |
10 | Dec 12 | Development Strategies, Algorithmic Complexity [slides] Week 10 Lab Handout [Programming Topics][ Exercise] |
PA3 due, PA4 out Reading: Guttag 4.2, 9, Downey 3.12, Appendix B |
11 | Dec 19 | C for Python programmers [slides] Week 11 Lab Handout [Programming Topics] |
Reading: Deitel & Deitel (C How to Program) 2, 3.1-3.6, Kernighan and Ritchie 2, 3.1-3.3 |
12 | Dec 26 | Midterm exam 2
|
PA4 due, PA5 out Reading: The Resurgence of C Programming: Do You Still Need to Write Code to Build Cool Machines?, Mike Barlow |
13 | Jan 2 | Switch statement, Loops and Functions in C [slides] Week 13 Lab Handout [Programming Topics][ Exercise] | Reading: Kernighan and Ritchie 3,4, Deitel & Deitel (C How to Program) 4,5.1-5.6,6 |
14 | Jan 9 | Pointers and Strings [slides] | PA5 due Reading: Kernighan and Ritchie 5.1-5.5, B3, Deitel & Deitel (C How to Program) 7.1-7.9, 8.1-8.6 |
Programming Assignments
- Assignment 1
- Assignment 2
- Assignment 3
- Assignment 4
- Assignment 5(Due: Jan 12, 2019 (23:59:59))
Resources
General purpose text editors
- Vim (Linux, OS X, Windows)
- Emacs (Linux, OS X, Windows)
- Sublime Text (Linux, OS X, Windows)
- Week 10 Exercise Input File
Setting up Python
PyCharm Edu Integrated Development Environment (IDE) will be used in laboratory classes for learning how to program with Python.
- PyCharm Edu and Python Installation Guide
- Getting Started with PyCharm Edu - a quickstart manual
- Guide to compiling your code on department servers
Resources for C language
Tools for C
Standard Environment
The most efficient way of developing a C program is to use a Unix environment:
- Command-line
- Compiler: gcc
- Debugger: gdb, valgrind
- Editor: Vim, Emacs, or Sublime Text
To mimic a Unix programming environment on your own computer, you have the following options:
- On a Linux distribution:
sudo apt-get install build-essential
or equivalent. - On Mac OS 10.6.6 or later: Install Xcode from the App Store, open it, go to Preferences > Downloads > Components and download "Command Line Tools".
- On Windows: Install cygwin. Please check the packages
gcc-core
,gcc-g++
,gdb
.
IDEs for C
Your programs need to work in the standard environment as we evaluate them on dev.cs.hacettepe.edu.tr
. However, if you'd like to use a GUI, these are the IDEs that seem to work well:
- Code::Blocks (Linux, Mac OS X, Windows)
- Eclipse (Linux, Mac OS X, Windows)
- Xcode (Mac OS X)
- Visual Studio (Windows)