GIVE NOW about ocw help & faqs contact us
6.S096 | January IAP 2013 | Undergraduate

# Introduction to C and C++

### Course Meeting Times

Lectures: 2 sessions / week for 4 weeks, 1 hour / session

Labs: 2 sessions / week for 4 weeks, 1 hour / session

### Course Description

This course provides a fast-paced introduction to the C and C++ programming languages. You will learn the required background knowledge, including memory management, pointers, preprocessor macros, object-oriented programming, and how to find bugs when you inevitably use any of those incorrectly. There will be daily assignments and a small-scale individual project.

### Software

#### Standard Environment

It’s most efficient for the staff if everyone uses the same environment:

- Athena command-line
- Compiling: gcc, g++
- Debugging: gdb, valgrind
- Editing: nano, pico, vim, or emacs

You can mimic that environment on your own computer:

- Windows: All the necessary packages (except valgrind) are available in cygwin (gcc-core, gcc-g++, gdb).
- OS X: Install Xcode from the App Store, open it, go to Preferences > Downloads > Components and download “Command Line Tools”.
- Linux: `sudo apt-get install build-essential` or equivalent.

#### IDEs

If you’d like to use a GUI instead (and there are many good reasons to do so), we’ll try to help you out, but:

- Your programs still need to work in the standard environment, so you should test them there.
- One of our primary debugging tools (valgrind) may not be available in your IDE.

Nevertheless, these IDEs seem to work well:

- Code::Blocks (Windows, Linux, OS X)
- Eclipse (Windows, Linux, OS X)
- Visual Studio (Windows)
- Xcode (OS X)

## Course Info

##### Instructors

- Tom Lieber
- Kyle Murray
- Frank Li

##### Departments

- Electrical Engineering and Computer Science

##### As Taught In

January IAP 2013

##### Level

Undergraduate

##### Topics

- Engineering
  - Computer Science
    - Programming Languages
    - Software Design and Engineering

##### Learning Resource Types

assignment Problem Sets
notes Lecture Notes
group_work Projects
assignment_turned_in Programming Assignments with Examples

# You are leaving MIT OpenCourseWare

Please be advised that external sites may have terms and conditions, including license rights, that differ from ours. MIT OCW is not responsible for any content on third party sites, nor does a link suggest an endorsement of those sites and/or their content.