AP
Computer Science (A)

COURSE OUTLINE & CLASS PROCEDURES
Link
to CLASS
NOTES BY DATE
COURSE OVERVIEW: AP Computer science provides an introduction to the world of object oriented programming using Java, the rapidly developing language that provides cross-platform access and widespread application. The major focus is on concepts that will be applicable to any object oriented programming language. Students will also experience working with a multi-file large case study provided by the CollegeBoard.. Beginning in 2008 the study will be the GridWorld Case Study. (See the link below.)
PREREQUISITE: Students who take AP Computer Science must have successfully passed the class in Visual Basic entitled Software Design, which includes a study of computer history, hardware, control structures and algorithms. Exceptions to this policy have been made for students who can fully demonstrate equivalent skills.
ASSUMPTION:
During this semester students will work in the Math Computer Lab.
Students will treat all equipment with respect.
Students are expected to treat each other with respect as well.
Students are encouraged to work together. Mindless copying is
prohibited. Vandalism,
profanity in programs, tampering with someone else’s programs, misuse of
equipment or cheating will result in an automatic “F”on projects and loss
of Lab privileges.
LAB and PROJECT DEVELOPMENT: Students will go to the math lab on most mornings to work on assignments. Students are encouraged to work together to troubleshoot and debug programs. Logical errors, compiling errors and runtime errors will be observed. Students should try to debug their own logical errors by placing strategic printouts to find mistakes. Students should become familiar with the meaning of compile error messages. Examples of these are division by zero, out-of-bounds, NullPointerException, casting errors. Examining printed code can help analyze errors in structure. Many editors will highlight the pairing of braces which may also help with debugging. Students should not hesitate to ask for help when stuck with a problem. Programming is an art, a skill. Practice is needed to become proficient. Students are encouraged to experiment with extensions of assignments as time permits. Students should analyze programs from the "top-down" and from the "bottom-up" when appropriate.
TEXTBOOKS (with
textbook and author links)
PRIMARY TEXT: Lewis, John, William Loftus, and Cara Cocking. Java Software Solutions for AP Computer Science. Pearson Education, 2004.
Litvin, Maria, and Gary Litvin. Java Methods A & AB: Object-Oriented Programming and Data Structures, AP Edition. Andover, MA: Skylight Publishing, 2001. (http://www.skylit.com)
Schram, Leon, Multiple-Choice and Free Response Questions in Preparation for the AP Computer Science ("A" & "AB") Examination, D&S Marketing Systems, Inc.,2004
Reference Book (for student questions) Deitel, H.M. &Deitel, P.J., Java, How to Program, Fourth Edition, Prentice Hall, 2002
GRADES: Points will be given for various activities:
Homework
Projects
(larger programs)
Tests (all tests are cumulative, approx. one every 2 wks) Appropriate use of lab time
Quizzes (follow homework
exercises)
Lab
activities (mini
programs)
PROCEDURES
FOR PROJECTS:
After the introductory lessons on programming you will be assigned
programs to write on a regular basis. Class lectures will provide you
with "hints" as how to proceed and information about the language
structure and syntax. Some programs will be exercises to be completed in
a day or two. Some may last for up to a week.
You should finish the assignments as soon as possible.
The purpose of these programs is for you to gain control of the
language and to learn important concepts. Time does not permit us
to make each one a "work of art."
Points will be deducted from programs that are not turned in a timely
manner. When a program is finished it will have to be tested in class.
Students are encouraged to download the free java compiler for use at home.
See the link to Maria Litvin's web page for setting up the Java compiler.
TESTS: Tests and quizzes will be given and graded in a conventional manner.
Students have 3 days to make up a missed quiz or test.
EXTRA TEST: Students not taking the AP exam will have a cumulative test on the day of the AP exam.
Students taking the AP exam will be exempt from this test.
FINAL EXAM: School policies will be followed concerning the taking of final exams.
GRADES: Grades will be determined by dividing points by possible points and determining a percent grade.
93-100 A
85-92 B
75-84 C
70-74 D
69 and below F
AUDIO VISUALS In the course of this term some math videos may be shown during class time including:
The Pirates of Silicon Valley, Bill Gates, Biography and Computer History
AP CONTENT and resources: Priority in study should be given to the objectives of the AP computer science curriculum which stress the fundamentals of programming.
ou can see the objectives of the AP computer science committee.
Collegeboard AP Computer Science A at:
http://www.collegeboard.com/student/testing/ap/sub_compscia.html?compscia
http://apcentral.collegeboard.com/apc/public/courses/teachers_corner/4483.html
GridWorld Case Study
http://www.collegeboard.com/student/testing/ap/compsci_a/case.html?compscia
Course Description from AP
http://www.collegeboard.com/prod_downloads/ap/students/compsci/52435 APCompSci-Locked.pdf
Summarized content (Periodically check this list--Make sure you don't forget these terms.)
UNITS OF STUDY (These
may be modified as needed based on student understanding.)
Multiple
choice questions from Schram book and reading selections from Lewis are
assigned for homework once topics have been introduced or covered. (Many
students read ahead. Litvin book
assigned to those who finish the Lewis book.)
|
Unit Title
|
Topics Covered (Objectives:
The student will gain mastery of
all indicated commands and understand their interaction with the cpu.) |
|
|
Java in Context or More
Computer History Lab: "The Hello Program" Getting everything to work. COMPUTING IN CONTEXT Chapter 1 |
The need for portability between platforms, information hiding, encryption, privacy, encaspsulation. The
confusion about Java 1 and Java 2 The
swing classes Jbutton vs
Button The
Java virtual machine, bytecodes versus complete compiling.
Applets and Applications Review
of Computer hardware design, primary and secondary memory, processors,
peripherals (the monitor and printer are really files)
Network use vs single-user systems
Open
architecture of computer design and modulation of computer code
(reusable components) Intellectual
property rights. Stealing
is stealing even if electronic.
Ask for permission when using someone else's materials.
Site sources. Give
credit where credit is due. The Java Runtime environment (JRE)and the Java development kit (JDK) |
|
|
How to do the "Same Things" we did in VB Control Structures in Java STRINGS and the Input problem Lab: write the "guessing game" too high, too low, etc. Lab: Write
Euclids Algorithm for GCF Sieve
of Eratosthenes for finding prime
numbers. Chapter 2.1-2.4 |
DATA STRUCTURES
int, double, boolean, etc. A comparison of for loops and control structures (if) If-else,
while, do while, switch, etc % for Mod. Math.pow for ^ ; increment ++, -- ,etc VB
commands and Java commands. Review of
Binary and Octal number
systems Strings as input using the JOptionPane method which is similar to an Input Box in VB. This requires the use of the Integer and Double wrapper classes to parse strings for input of int and double. Arrays of
primitives, Static Arrays SAVE
Euclid as a very useful REUSABLE
CLASS. PROGRAM IMPLEMENTATION |
|
|
SOME THINGS ARE "Different" or
"WE'RE not in Kansas any more!" Lab: Master arithmetic,
Casting of variables, Rounding, Math.floor and Math.ceil Chapter 2.5 |
The need for type
casting. You can be betrayed by arithmetic. Java is a
"grown-ups language." We have to count from zero and
we have to be sure where the arithmetic is sent.
Integer arithmetic will cause 5/2 to equal 2. Round off error
(storage of variables) Rounding errors (found in grade
management programs) Rounding to the
nearest ten or tenth, etc. Scope of variables
& the garbage collector. Importing calls to
Java library classes AND/OR
Boolean Algebra and DeMorgan's Law Pre and Post Conditions |
|
|
Everything is an object (except primitives) A together project using gui objects to re-create an earlier VB program assignment for times table flash cards.
Lab: Use the javax.swing classes to recreate a flash card program for multiplication tables.
Add personality. Students who finish before classmates may want to make an applet. Modify the drawing program on p. 107 with a mouse listener.
Chapter 2.6-2.11 |
The use of the dot member to access methods of a class. VB was Object Oriented all the time! In Java properties are called instance variables Events are called Methods. Action Listeners show the implementation of one class by another and the use of an abstract inner class. After this project students who want to may use gui components for projects. Their use is not required. |
|
|
My Pet #1 Our first homemade class Two files work together: The Pet class and the TestPet class which contains the "main" and tests
the functionality of your class.
Add personality! |
OBJECT ORIENTED
PROGRAMMING DESIGN How to make a
class. Instance variables, encapsulation, instantiation,
constructors, static variables, method oveloading, accessors,
mutators, return types, parameter lists PROGRAM ANALYSIS |
|
|
Strings for real! Labs: Jumble words, Change last name, first name format to first name last name (as needed by the secretaries who type up the graduation program.), A Jumble guessing game. Twelve Days of Christmas. Pig Latin, Palindromes. Conquer Strings! |
Substring concatination, etc the .equals() method and its necessity. Arrays of Strings |
|
|
A Working Class your choice: Make a MyFraction class (use
your GCF module for reducing fractions --reusable
code!) or a MyComplex class that mimics the function of the calculator
Chapter 4,5 |
Solve the problems that arise from making a useful mathematical class. More practice with function overloading with multiple constructors, methods, returns |
|
|
NewPet Lab: NewPet an abstract class Make several classes that extend NewPet. For example MyDog, MyCat, MyFish
Chapter 7 |
Data Abstraction, Array Lists Encapsulation The use of super, Overriding a method The null pointer "is-a" and "has-a" relationships. Apply functional decomposition Properties of ArrayLists so that the TestPet Class can be used to demonstrate polymorphism |
|
|
John Conway's "Game of Life" Lab: The Game of Life Chapter 6 |
Two dimensional arrays Concatinate a string to represent the matrix and display on JoptionPane Analyze the problem of the boundary cases. |
|
|
Recursion Lab: Fibonacci and Factorial Chapter 8 |
A method that calls itself! How powerful! |
|
|
Sorting and Searching Lab: Sort, binary search, selection sort, insertion, mergesort, traversals, deletionsUsing ArrayLists and static arrays Chapter 6,8 |
STANDARD ALGORITHMS A comparison of efficiency The Big-Oh comparisons Applets that show efficiency: University
of British Columbia |
|
|
THE LARGE CASE STUDY A close encounter with the GRIDWORLD LAB:
Set up and use GridWorld Add
classes, constructors, and or methods |
Identify class structure/methods, etc. Analyze the program structure of the study, the naming conventions and appropriateness of data types. Black Box testing |
|
|
REVIEW,
REVIEW, REVIEW Lab: test anything you don't understand |
Practice AP tests Multiple Choice and Free Response Questions from past AP tests. |
HELPFUL Links
SUN
Download compiler:
http://java.sun.com/j2se/1.4.2/download.html
Older machines can use, less memory intensive version
.http://java.sun.com/products/archive/j2se/1.3.1_02/index.html
Sun
Tutorial:
http://java.sun.com/docs/books/tutorial/index.html
Swing
components
http://javaalmanac.com/egs/javax.swing/pkg.html
Setting
up your computer to run Java (Use the advice from Maria Litvin's Website)
http://www.skylit.com/javamethods/faqs/index.html
Pellissippi
State
http://pstcc15.pstcc.edu/facstaff/caarnold/
Syllabi:
http://www.pstcc.edu/departments/bct/csit1520.html
Connecticut
State
http://chortle.ccsu.edu/CS151/cs151java.html
Colgate
University for AP Computer Science
http://cs.colgate.edu/APCS/
MY
SYNTAX "cookbook":
HTML template for applets: Replace "MyClass" with name of
class in
3 locations; adjust width and height parameters as needed.
You can e-mail me with any questions at howel1@k12tn.net or teachhowe@hotmail.com