SYSC 2002 Data Structures and Algorithms
Winter 2011 - Assignments, Labs, Midterm and Quizzes
Compiler:
We will be using Dev-C++ as the default compiler for SYSC 2002.
Note that you may use whatever C++ compiler you want to write your programs, but you must ensure that your programs can be compiled in the Dev-C++ environment provided in the SCE labs.
We recommend that you use Dev-C++ as it can be downloaded for free at http://www.bloodshed.net/dev/devcpp.html. Chapter 2 of the notes has details on downloading and setting up the Dev-C++ environment for this course.
Note that Dev-C++ only works under Windows. If you have a Mac, we recommend Xcode. However, you still need to become familiar with Dev-C++ for lab tests, and all assignments will be marked using Dev-C++, so we recommend that you check that your assignments work as expected in the lab Dev-C++ environment. If anyone develops a stdstuff.h file (see below) for Xcode, please let us know!
Labs:
The labs for this course are in ME4390. Lab tests must be submitted from the machines in this room before the end of the lab period.
Assignments can be submitted
from anywhere on or off campus. However, the TAs will mark your
assignments on the environment in ME4390, so you are encouraged to
confirm that your programs work in the lab.
Marking Guidelines:
Here are the SYSC 2002 marking guidelines that
the TAs will be using for the lab tests and the assignments.
You should also review the ECOR 1606 style guidelines (link fixed Jan 3rd).
Midterm and Final Exams:
Information on the exams will be posted here when it is available.
Here is a sample midterm (with solutions) from last year. (Added Feb 11th)
Here's the crib sheet you'll get with your midterm. (Added Feb 11th)
Here are the midterm sample solutions. (Added Mar 15th)
Here are some old final exam questions for practice. Note that they are taken from many different old exams, so there may be some repetition, and there are certainly more questions that you will get! (Added Mar 15th)
Here are some important final exam notes and a copy of the Crib Sheet that you will be given for the final exam. (Added Mar 15th)
Lab Tests and Sample Lab Tests:
Lab tests will not be posted ahead of time. After the labs, they will be posted here. Sometimes sample lab tests will be posted ahead of time for extra practice.
Assignments:
Assignments will be posted here. If you want to get ahead, just ask me to post the next one!
Stdstuff.h:
All .cpp files should begin by including "stdstuff.h". This header file replaces all of the usual include directives (i.e. include directives for iostream.h and so on). It comes in three versions. One works for the Dev-C++ environment, one for the Visual C++ 6.0 environment and one for the Borland 5.0 environment. One advantage of using "stdstuff.h" is that it is more convenient than putting in all of the usual includes. The real reason for using it, however, is that makes programs "platform independent". A program written using "stdstuff.h" should work in any of the three environments (provided only that the correct version of "stdstuff.h" is used).
Programs which use "stdstuff.h" should "pause" before terminating if it
is necessary that the user be able to read the execution window before
it disappears. The sample program below should give the idea. In
the Visual case, of course, the "pause" is not really necessary, as
the development environment automatically looks after preserving the
execution window. The whole point, though, is that programs should work
in both environments. If you leave out the "pause" when working at
home in Visual, your program will work for you, but it won't work when
run in the Dev-C++ or Borland environments.
#include "stdstuff.h"
int main () {
.......
pause (); // ensure
that the execution window can be read before it disappears
return 0;
}
"stdstuff.h" for various environments (e.g. dev/stdstuff.h)
Assignment Submission:
Assignments are submitted electronically: