There are two different, but overlapping exams that are part of the APCS program. The A exam corresponds roughly to CS1, the AB exam corresponds roughly to CS2. All topics that are part of the A course are also part of the AB course.
A description below describes the proposed APCS C++ subset. Basic parts of C++ common to other programming languages (e.g., while and if/else statements) are not mentioned, but are part of the APCS subset. The subset description does not address all the topics that are part of the APCS courses. The full list of topics can be found in the College Board's AP Course Description in Computer Science booklet. For example, sorting and searching are parts of both courses and are listed in the Course Description.
The subset provides several auxiliary classes, including vector and string classes with facilities similar to those available in languages like Ada, Java, and (extended) Pascal.
An important feature of the subset is its inclusion of classes and related features that facilitate the design of programs based on modern concepts of data abstraction, encapsulation, and information hiding. Object-oriented programming in its full glory is not covered --- in particular, features of C++ that allow classes to be related by inheritance are not part of the subset. The subset does, however, support the use of what is often called an "object-based" approach to programming, emphasizing data abstraction and encapsulation.
C++ counterparts to Pascal features that allow avoidance or easier detection of common programming errors are retained in the subset. Examples are type-safe input and output and range-checked vector and string classes.
C++ is not C. The AP CS subset includes stream input/output, reference parameters, and definition of constants using the const keyword, eliminating the need for their C counterparts. The vector and string classes provided in the subset are significant improvements over C's pointer-based realizations of arrays and strings.
The subset omits a number of C++ features that are not necessary to design and implement large programs as part of an AP CS course. Some features, such as inheritance, are not included because they are not part of the AP CS course. Other language features either are redundant, are easily replaced, or do not provide sufficient benefit to be included in the subset. What remains is sufficiently extensive to permit large and complex programs to be developed using generally accepted C++ idioms. Additional details of the AP CS subset of C++ are summarized in the following pages.
A rationale explaining parts of the subset is accessible as well.
In the next month, versions of these classes tuned to particular compilers will be made available. In particular, some compilers, including Borland Turbo C++ (for Dos/Windows) and Metrowerks Codewarrior (for Mac OS) do not include the type bool as a built in type. A header file bool.h is available for use with these compilers. In this preliminary release, the #include for this file will need to be uncommented, e.g., it appears as a comment
apqueue.h and apqueue.cpp