Download files.Request a complimentary examination copy.Ordering information.About Lawrenceville Press.

Compiling Marine Biology Case

Teaching Hints Graphics About the graphics library



Libraries: The MBCS was designed to work with the AP libraries (apstring, apvector, and apmatrix). While the Lawrenceville Press libraries (String, vector, and matrix) are nearly identical to the AP libraries, the String library differs in one important respect: including the string.h file automatically retrieves the string.cpp implementation file. This approach, while very convenient for novice programmers, is incompatible with programs, such as MBCS, that use interrelated classes. We recommend that, when presenting the MBCS, you download and use the original AP libraries to minimize complications. These libraries are available at the College Board site, and should be placed directly into the "include" directory of your compiler, e.g., C:\Program Files\Microsoft Visual Studio\VC98\Include or C:\BC45\Include or C:\BC50\Include, etc.

Part I: While it is possible to modify Part I of the MBCS to work with the Lawrenceville Press libraries and avoid the use of a project, we recommend that you take this chance to help students understand the concept of a project, and also understand that there are two sets of very similar libraries. To get Part I running, you should:

Download and install the AP libraries into the Include directory. (Get libraries here.)

Download the Part I files into a single directory on your hard drive. (Get MBCS Part I files here.)

Open your compiler, and create a "project". You should create a "console" or EasyWin project, initially empty. This process will vary slightly from compiler to compiler. Note that, in the case of Borland 4.5, you may find that .RC and .DEF files are placed in the project. You should delete these files from the project.

Add all of the Part I .cpp files to your project, including fishsim.cpp, fish.cpp, and randgen.cpp.
Add the apstring.cpp file to your project. You will need to navigate to the Include directory where you stored this file.

Compile, link, and execute the program.

Part II: Part II requires a similar approach. Before trying Part II, we suggest that you make sure that you have Part I running successfully with a project and the original AP libraries. Assuming you have done this, you must next:

Download the Part II files into a single directory on your hard drive. (Get MBCS Part II files here.)

Note: As distributed by the College Board, the MBCS code requires that the AP libraries (apstring, apvector, apmatrix) be installed in the same directory as the MBCS code. If you prefer to place the libraries in the standard include directory, you will need to edit each of the MBCS #include statements to indicate (for instance)

#include <apvector.h> rather than #include "apvector.h" and repeat this process for apstring and apmatrix.

Open your compiler, and create a "project". You should create a "console" or EasyWin project, initially empty.

Add all of the Part II .cpp files to your project, including fish.cpp, environment.cpp, randgen.cpp, and so on. This is done as describe above for Part I.

Add the apstring.cpp file to your project. You will need to navigate to the Include directory where you stored this file. Do not, however, add apvector.cpp or apmatrix.cpp. These files need never be added to a project.

Make sure that Fish.dat is in the same directory as the fishsim.exe (the program file).

Compile, link, and execute the program.


 

See what our customers have to say about our materials!

Home - Site Map - Download - Exam Copy - About Us
Office 2003 - Office XP - Office 2000 - StarOffice 8
Dreamweaver MX 2004
- Visual Basic 2005- Visual Basic .NET - Java
ISBNs and Ordering Information - Customer and Technical Support - Conferences - Text Evaluation
Copyright 2007 Lawrenceville Press, Inc.
A division of EMC Corporation