no slides. See final exam tips.
How do I ace the final exam?
Homework: Finish final project and study for the final exam.
no slides.
What is the big deal with "overlapping sub-problems" that often occur in recursive algorithms?
What is Dynamic Programming?
What are stochastic models?
What is the Random Walk problem?
C++: do/while, switch
What is the difference between an interpreted vs. a compiled program?
What does it mean for a language to be considered Turing-complete ?
Other language examples (Ruby, Python, PHP, Java).
Homework: Finish assignment FluPolicy and Final Project.
no slides
Homework: Continue assignment FluPolicy and Final Project.
no slides. example code
What is a variable identifier, really?
Where do values actually 'go' when they are assigned to a variable?
What is a memory address?
What is a pointer?
Why do pointer types matter?
Why is it important to be able to find things in constant time?
What is asymptotic ("Big-O") notation? What does it represent?
What do real world problems have to do with algorithms?
How can you compare algorithms and determine if one is "good" vs. "bad"?
Homework: Continue final project and FluPolicy.
no slides. example code
Bonus: What is recursion?
What is meant by "dynamic memory allocation?"
How do you tell the computer to allocate memory for you? (new)
How do you tell the computer to release allocated memory? (destroy)
How can you dynamically allocate memory for an array of objects?
Homework: Read section 9.4 and complete assignment AllocatedTriangles.
no slides
How do you overload i/o operators (<< and >>)?
Homework: Complete assignment FluVaccine.
How do you ace the midterm?
Homework: Study for midterm, complete assignment TrianglePrep.
slides, friend function example, solid-friend-operator.cpp, CubeClass.h, CubeClass.cpp
Classes review, MonthClass review.
What is operator overloading and why is it convenient?
How do you overload operators?
What is a friend function and how do you use one?
Homework: Read 10.1 & 10.2, complete assignment SolidFriendOperator.
no slides. see SimpleMonthTest.cpp.
Homework: Complete assignment MonthClass and FluSimulation.
see Professor Hellman's slides.
const integer data members
Arrays as data members
arrays of objects
returning anonymous objects
Homework: Complete assignment FluSimulation.
no slides. see accessors and class I/O.
Let's review functions, scope, classes and objects, yay!
What are accessor methods and what pattern do they almost always follow?
What common pattern should you remember for a class' I/O functions?
Homework: Complete assignment PlayerClass.
const functions, StudentFluno slides
What are getters and setters?
What canonical pattern do typical getters and setters follow?
Homework: complete assignment StudentFlu.
code: solid-class.cpp, CubeClass.h, CubeClass.cpp
What is an object? How do we program with real-world objects?
What are some general properties of objects?
How do you use the dot operator?
What is a class? (How do you tell a computer what your real-world object is like?)
What do keywords private and public do?
How do I define a class? How do I implement member functions?
What is a constructor? How do I declare one? How do I use one?
Homework: Re-Read 8.1, 8.2, 8.4, 8.7 Complete assignment SolidBeginningsClass.
no slides
What is an object? How do we program with real-world objects?
What are some general properties of objects?
How do you use the dot operator?
What is a class? (How do you tell a computer what your real-world object is like?)
Homework: Read 8.1, 8.2, 8.4, 8.7 and complete assignment WeekSchedule.
no slides
Homework: Choose your final project partner and complete assignment OverloadedInputValidation.
stream Objects, Function Overloadingno slides. see function overloading
What is function overloading and how do you do it?
What is the proper return type for functions that return stream-related objects?
Homework: Choose your final project partner and complete assignment ThresholdDataFunction.
rand()omnessWhat is special about computers and randomness?
What is a random seed value and why might you always need one?
How do you use rand() and srand() properly?
Why should objects always be passed by reference?
Fisher-Yates shuffling algorithm review.
Final Project announcements.
Homework: Choose final project partners, Read 5.5 and complete assignment ShuffleWords.
no slides
Homework: Complete assignments LetterFrequencyByFunction and ShiftCipherByFunction.
How do you declare a function that doesn't return anything?
How do you declare a function that doesn't require any input?
How should you declare const parameters?
What are static const global variables and how do you declare them?
How are array arguments passed?
How do you declare a formal parameter that is an array? (1d, 2d)
What is the BubbleSort algorithm?
Homework: Review slides and complete assignment BubbleSort.
no slides
Homework: Complete assignments QuadraticRoots and VoidReferenceSolidMetrics.
slides and sample code
Functions review
How do you use a header (.h) and implementation (.cpp) file to define your functions?
What is scope?
What is pass-by-value? What is pass-by-reference?
Homework: Read 5.3 and complete assignment ReferenceSolidMetrics
What is a function, in general?
What is a function in C++?
What are the parts of a function?
What is a user-defined function? What is a library function?
What is a formal parameter? What is an argument?
How do you declare, implement and use a function in your program?
What is a header file?
Homework: Read 5.1 & 5.2 and complete assignment SolidBeginningsFunction.
no slides
How do I ace the midterm?
Homework: Study for exam 1.
string Classslides and string API
Who is Ivan Sutherland?
What is "Object-Oriented Programming?"
What is the difference between a class and an object?
How does a string object behave (what functions does a string object provide)?
Homework: Complete assignment NamePrinter.
no slides
Homework: review chapters 6.1, 7.1 & 6.9 and complete assignments LetterFrequency and BinarySearchWords.
Array review
What is a two-dimensional array?
What are some ways to envision the structure of a 2D array?
How do you access and assign values in a 2D array?
How do you typically loop over a 2D array?
Homework: read chapter 6.9 and complete assignment PowerPlantMax.
What data structure can you use to hold multiple values of a particular type?
What is an array?
How do you declare and initialize an array?
How can you assign a value to one position in an array?
Why does array size matter?
How can you create a loop to access/manipulate all values in an array?
Homework: read chapter 6.1 & 7.1 and complete assignment ThresholdData.
no slides.
How can you get a whole line of text using getline()?
What unwanted behavior happens when you try to open both an ifstream and an ofstream on a file simultaneously?
How can you capture more than one line of input from cin?
Homework: Complete assignments SutureRejects and CodeAdvice.
What is the general boilerplate code for basic file I/O?
How can you tell your program to create a file?
How do datatypes affect the behavior of reading input streams?
Homework: Complete assignment ShiftCipher.
How do you tell your program to open and close a file?
How can you get your program to work with the contents of a file?
Which C++ library do you need to work with filestreams?
Homework: Complete assignment IntegerChars.
Homework: Complete assignment LoopRunTimes and TimberRegrowthYears.
for loops)How do you use a for loop?
How can you escape from a loop?
Homework: Complete assignment FindPrimes.
while loops)How do you use a while loop?
What is an infinite loop?
What is the difference between while and do while?
In general, when should you use a while loop rather than a for loop?
Homework: Read 3.4. Complete assignment FiveModSum.
if, else if, InputValidation, PaperScissorsRockHow do you use an if statement? (review)
Homework: Complete assignments InputValidation and PaperScissorsRock.
What do we mean by procedural?
How do you use an if statement?
How are ints and bools related?
How do cin and cout treat bool values?
What are ASCII numeric codes for characters?
Homework: Read 3.3 (skip 'conditional operator' and switch). Complete assignment AsciiExplorations.
Who is George Boole?
How can I use screen specs, flowcharts, and pseudocode to guide my construction of a program?
What do the weird flowchart symbols mean?
What is a boolean expression?
Remember: expressions get evaluated and yield a value
What are the boolean operators and how do they work?
Homework: Read 3.1, 3.2. Complete assignment BooleanExpressions.
What happens when you have operations with different variable types? (p50 - 51 "mixed operations")
What is casting? (p51)
Refer to (p50- 51) "mixed operations", (p51) casting. Review on Monday 9/6.
Homework: Complete assignment TKtoTF and AminoAcidAverageWeight.
Who is Alan Turing? What is a Universal Machine?
Comments, case sensitivity, variable names, types, variable declaration syntax, constants, operators, increment/decrement, cmath library, functions (in brief).
Simple text formatting with cout (see pages 58 - 62).
Homework: Finish reading chapter 2.1 - 2.4, 2.7. Complete assignment VolumeOfSphere.
slides and supplement
Who is Bjarne Stroustrup?
What are some "cool" things programs can do?
How would you describe the programmer's typical toolchain?
What is the difference between a syntax error and a logic error?
C++ program structure, preprocessing directives, main(), code blocks, variables, types, I/O, CIN, COUT.
Homework: Read chapter 2.1 - 2.4, 2.7. Complete assignment MilesToKilometers.
Set up your development environment.
Compile and run a program.
Understand what we just did.
Homework: Finish chapter 1 (skip 1.4). Complete assignment SolidBeginnings.
Introductions
What's a modern computer system? What is hardware? Software?
What do we mean by abstraction?
What is a computer program?
Who is Ada Lovelace?
Why are computer languages so weird?
Why program?
Administrivia.
Homework: Read chapter 1 (skip 1.4). Enroll in blackboard course. Read and understand the syllabus.
< > ! * ' ' #
^ " ` $ $ -
! * = @ $ _
% * < > ~ # 4
& [ ] . . /
| { , , SYSTEM HALTED
Waka waka bang splat tick tick hash,
Caret quote back-tick dollar dollar dash,
Bang splat equal at dollar under-score,
Percent splat waka waka tilde number four,
Ampersand bracket bracket dot dot slash,
Pipe curly-brace, comma comma CRASH.
Fred Bremmer and Steve Kroese, 1990 Infocus
Justin Hall's breakdown video.
A description of Live Coding at Shunt Lounge 1 Oct 2009
Highly recommended viewing (not just about Archaeopteryx).
If Giles postmodern programmer-bum story is too much for you, here's a more pragmatic essay.