Announcements

May 11, 2011

We've been receiving a number of questions about how to create a new C++ project without any starter code (you'll need to do this for Evil Hangman). Keith wrote a super informative guide to doing exactly this for Windows, Mac, and Linux. The handout is located here.

Note: you should be able to use Visual Studio 2010 without any problems now, since none of the CS 106B libraries need to be included. We also do not have experience working with XCode 4 yet, so please let us know if you run into any problems.

Good luck on the assignment!

April 29, 2011

Patrick talked about the Stanford CS section leading program in lecture on Tuesday. We strongly recommend you visit the website and apply as soon as you have a chance. The deadline is in two weeks. It's a fantastic program, and we promise you won't regret it. We will be sending a follow-up email with specific details on how the program works. There is also an info session next week on Tuesday, May 3 at 7:00 pm in Gates 104. If you have any questions, we would be happy to answer them!

The second CS 106L assignment, Evil Hangman, has been posted on the website. It will be due Thursday, May 12 at 11:59 PM. Have fun with the assignment and let us know if you think of any cool extensions!

April 9, 2011

Just a reminder that Assignment 0: Graphviz is out. It is due in two weeks on Thursday, April 21 at 11:59 PM. You can get the assignment handout and starter code on the assignments page.

Homework help hours start this week. They are from 8 PM to midnight on Tuesdays and Wednesdays in the LaIR, which is on the second floor of Tresidder Union. There is a special computer where you can sign up for help. Please make sure when you sign up that you specify it is for CS106L help because we have a special CS106L staff that will prioritize 106L students.

For those of you using Visual Studio 2010, the graphics library on the first assignment is not working. We are currently working on rewriting these libraries, but it may take some time. We recommend that you use Visual Studio 2008, or switch to a cluster machine. If you are unable to do either, please let us know as soon as possible.

April 7, 2011

There are a few important points based on Tuesday's STL containers lecture that I want to briefly explain in more detail.

First, the code for Lecture 2 (Tue. April 5) includes a few extra files that weren't covered in lecture. basicqueue.cpp shows basic code using the STL queue. pushbacktt.cpp is a time trial that compares the vector and the deque in speed based on repeated use of push_back (they perform roughly the same).

Second, I introduced the idea of creating a vector of a specific size by declaring [ vector myVector(10); ]. Be VERY careful not to confuse this with the CS 106B/X version of the same thing [ Vector myVector(10); ]. In the 106B version, the number ten is just a size hint which makes adding things to the vector more efficient if you can guess how large it will be ahead of time. However, the vector STILL starts off empty, with size zero. With the STL version, the vector actually has ten copies of the number zero. You can similarly specify a size hint to the STL vector by calling [ myVector.reserve(10); ] after it has already been created.

Third, the quick reference guide comparing some STL containers and their CS 106B/X counterparts is in the "Lecture Material" section under Lecture 2.

Finally, we didn't cover every single vector and deque function available, and there are quite a few more interesting ones. The C++ reference website, www.cplusplus.com, has a fantastic list of all of their methods. Be sure to check them out!

April 1, 2011

Next Tuesday's lecture will introduce a new topic, the STL containers. We will assume you know what a stack and queue are, which Professor Cooper was originally going to cover in CS 106B on Monday. However, due to a change in plans, that topic was moved to Wednesday.

For those of you currently enrolled in CS 106B, we strongly urge you read the relevant pages in the 106B course reader. The reading consists of eight pages of light reading, which we have uploaded to the CS 106L website under the "optional reading" section for lecture 2. Don't worry too much about the syntax of the 106B Stack and Queue; simply make sure you understand the basic concepts.

You can access the reading as a PDF file here:
CS106B Stack and Queue (PDF).

March 29, 2011

Our first lecture is today at 4:15 pm. However, our enrollment just exceeded the capacity for our current classroom, 260-113. We will be moving class to 420-40. Looking forward to seeing you all there!

February 18, 2011

Welcome to CS106L! We've got an exciting quarter in the Spring and we are really looking forward to all the awesome material we are going to cover. The class will be meeting on Tuesdays and Thursdays from 4:15 to 5:05 in 260-113.

If you have any questions about the class, feel free to email us at: cs106l@cs.stanford.edu.

This class is appropriate for almost anyone who wants to expand his or her knowledge of C++. If you have only a rudimentary background in C++, this class will quickly fill you in on some of the more advanced C++ concepts and syntax along with a solid understanding of the libraries. For those of you with many years of C++ experience, this class will almost certainly cover topics you haven't been exposed to - after all, C++ is an enormous language!

If you are interested in what the class is going to be covering, feel free to browse through the course reader, or take a look at the website from Fall 2010.