Introduction to computers and programming Instructor: Alex Iskold
Course information l section’s home page can be found at l students registered for this section may not attend other sections l September 16th at 1:20, 14 Washington place l syllabus
Important dates l 9/21 - last day to add without permission l 9/22-28 last day to add with permission (see Robin Simon, room 404 WWH) l 9/28 - last day to drop a course l 11/2 - midterms are graded and returned l 11/9 - last day to withdraw with ‘W’ l 12/13 - last day of classes
Final exam l December 23 l no early exams will be given, don’t plan to leave before this date (you presence during final exam is required) l you may reschedule final if [and only if] it conflicts with two or more exams given the same day/time
Incomplete l There will be none
General department tips l Prerequisites –Basic computer knowledge (on/off) –Elementary algebra l Regular lab attendance –start using labs early and use them regularly –bring up the problems to my attention
Knowledge sharing & cheating l discussions of material are encouraged l everyone is responsible for their homework l assignments may not be copied l CS department will take severe actions if you caught cheating
General CS related questions l Robin Simon, Room 404 WWH
Asking questions l the question is not ‘Should I ask?’ l the question is ‘When should I ask?’ l during lectures l l office hours
Questioning l understanding concepts and applications –otherwise confusion & disinterest l ability connect concepts –quadratic equations and functions l why did people invent this concept? –otherwise why do we need it?
Questioning l can we reproduce their thought process –tough –most important l nothing should be taken as given l conceptual vs. detailed understanding –if possible, we want to understand the details l once details understood, create abstraction
Occam’s razor l things should be complicated, but no more than necessary
Lecture 1 Few people think more than two or three times a year. I have made an international reputation for myself by thinking once or twice a week. George Bernard Show
What is computer?
l machine capable of performing certain tasks –better than we are! l what are the requirements? –humans: sense organs act as input –humans: brain is CPU
What is programming?
l making computer perform certain tasks –compute something l computation is a fundamental part of our lives (more than many people think) –DNA –brain l how do we make computer compute?
Language issues l we need to be able to ‘tell’ computer, so we need a language l humans: language is an instinct l computer and natural languages
Binary encoding l electrical things… l 0 = 0, 1 = 1, 2 = 10, 3 = 11, hmm… l 1 + 2? l 1 = , 2 = , + =
Higher level languages l Assembly language l Procedural languages –FORTRAN, Pascal, C l Functional languages –LISP, Prolog l Object-oriented languages –Smalltalk, C++, Java
Looking for interpreter l computer understands only 0 and 1 l 100 Frenchman & 1 American l compilers & interpreters
Compiler l syntax vs.. semantics
Computer as a ‘Black box’ l don’t need to know details l this our first abstraction
One more thing - memory l grocery shopping l human memory l storing and running programs l modeling memory as an array of bits l finite space problem l Cantor’s hotel problem
What is algorithm?
l grocery shopping l description of the sequence of action l plain English l pseudo code
Top-down vs. bottom-up l top-down approach l bottom-up l using diagrams for problem solving