Check it out! - Mesa Public Schools

advertisement
Course Title: AP Computer Science A
Instructor Name: Kathy Wooton
High School: Skyline HS, Mesa, AZ
SY: 2013-14
Email: kwooton@mpsaz.org
Course Description:
AP® Computer Science A is a yearlong course taught in a computer lab. Each student has access to a
computer every day. Experience in basic computer concepts, programming, HTML or web page design is
desired but not required. This class is a foundations class for any student who plans to pursue the fields
of computer science, engineering, information technology, or any other college major which requires
critical thinking. It is also a college prep class, so the pace is aggressive and a high level of attendance
and individual work is expected and required.
This course is taught using the Java programming language. It will teach object-oriented programming
methodology and the process of coding, testing, debugging and implementing well written and well
documented code. Students will learn to write object-oriented programs using classes, objects,
methods, inheritance and polymorphism. They will use the standard code and classes contained in the
AP® Java subset. They will also learn the GridWorld Case Study and be expected to take the AP®
Computer Science A Exam at the end of the year.
Major Text:
Lambert, Kenneth, and Osborne, Martin. Fundamentals of Java: AP Computer Science
Essentials, Fourth Edition. Boston: Cengage Learning, 2011.
Additional Texts / Printed Material:
Bergin, Joseph et al. Karel J Robot: A Gentle Introduction to the Art of Object-Oriented Programming in
Java. Redwood City, CA: Dream Songs Press, 2005.
Sierra, Kathy & Bates, Bert. Head First Java, 2nd Edition, Sebastopol, CA: O’Reilly Media, Inc. 2005.
College Board. AP® GridWorld Case Study. New Your. College Entrance Examination Board, 2008.
http://apcentral.collegeboard.com/apc/public/courses/teachers_corner/151155.html
AP Curricular Requirements
Curricular Requirement: The course includes all of the topics listed in the “Computer Science A”
column of the Topic Outline in the AP Computer Science Course Description.
C1 - The course teaches students to design and implement computer-based solutions to problems.
C2 – The course teaches students to use and implement commonly used algorithms.
C3 – The course teaches students to use and implement commonly used data structures.
C4 – The course teaches students to develop and select appropriate algorithms and data structures to
solve problems.
C5 – The course teaches students to code fluently in an object-oriented paradigm using the
programming language Java.
C6 --The course teaches students to use standard Java library classes from the AP java subset
delineated in Appendices A and B of the AP Computer Science Course Description.
C7 - The course teaches students to read and understand a large program consisting of several classes
and interacting objects. In particular, the course enables students to read and understand the current
AP Computer Science Case Study posted on AP Central.
C8 – The course teaches students to recognize the ethical and social implications of computer
use.
Course Planner
The resources list includes the following text references: Fundamentals of Java (FJ), Headfirst
Java (HFJ), GridWorld Case Study (GW), Karel J Robot (KJR).
Unit
(Weeks)
Title, Topics, and Student
Objectives
1
(1)
Introduction to JAVA and OOP
Topic:
 Intro to JAVA and BlueJ
Objectives:
 Identify JDK, IDE; download
for home use
 Understand development
environment, compiler,
input/output terminal
 Intro to OOP terminology –
class, object, method
 Write, compile and run
simple JAVA programs
2
(2-3)
Resources, Assessments, and
Strategies
Resources: HFJ, FJ
Assessments:
 “Hello World”
 Convert Temperature
Topic: Java & Computer Basics
Resources: FJ Ch. 1-2
Assessments:
 Computer hardware &
software
 Various little programs
using different types of
 Java terms: objects,
inputs and outputs
classes, loops, methods,
 (p. 55) Write programs to:
conditional statements
 Copyright laws, ethics and

Display student info
intellectual property

Calc. minutes / yr
Objectives:

Calc. & print
 Understand hardware and
momentum
software terminology: CPU,
 Homework: Create timeline
auxiliary devices, system vs.
of computer history and
application software, RAM,
significant advances (FJ 1.1)
ROM, LANs and WANs
 Quiz: Label parts of
 Understand purpose and
computer and describe
characteristics of copyright
function (FJ 1.2)
law, ethics agreements and Strategies:
rules of downloading
 Students must demonstrate
application of their knowledge
 Understand how different
of computer laws and ethics.
parts of a computer work
Correlation to
AP Topic
Outline
C1
C1
C3
C4
C8



together
Edit, compile, and run
simple Java programs
Use the Scanner class to do
input
Use System.out.print and
println to format output

3
(4)
4
(5-6)
Imagine you (the student)
have created some software
that can be sold. Write a
short paper explaining
copyright laws on proprietary
software, ethics involved and
the laws of intellectual
property. At some point,
would you (the student) make
your code open source?
Explain.
Purpose of many small
programs in this unit is to
build knowledge and
confidence. Also, begin to
solve compiler errors on their
own.
Topic: More Java Basics
 Binary Representation and
Conversion
 Random Number
Generation
 Purpose of class, class
launcher and main
statement
Objectives:
 Understand how to
convert numbers from
one base to another
 Be aware of pre-coded
methods or functions
and begin to use them
 Learn how to generate a
random number In Java
 Understand the main
statement – what it
invokes from where it is
coded
Resources: FJ Ch. 1.3, HFJ Ch 2
Assessments:
 Worksheets that define
Base 2, 8, 10 and 16; then
perform conversions to
Base 10
 Programs:

Guess Game

DrumKit

PoolPuzzle (annoys)
 Unit 3 Quiz
Topic: Defining Variables,
Arithmetic Expressions
 Declare, use and
understand variables
Resource: FJ Ch. 3
Assessments:
 Various Chapter Exercises –
evaluate expressions both
C1
C2
C3
C5
C6
Strategies: Start with template of
program and begin to fill in pieces
of code. Work on syntax,
understanding program flow,
solving errors and understanding
the purpose of basic statements:
declarations, assignment,
conditionals and loops, equality
and the main statement.
C2-C3
C4

Arithmetic Expressions
including mixed mode
 Comments
 Different types of errors
Objectives:
 Understand different types
of Java vocabulary:
variables, constants,
literals, reserved words and
comments
 Declare and initialize
variables and constants in
Java
 Understand mathematical
expressions in Java
 Understand how to use
casting
 Understand different data
types and their high and
low limits
 Correct use of the
assignment operator
5
(7-9)
Topic:




Conditionals and Looping
If and if-else statements
While loops
For loops
Nested Control with Break
Statements
Objectives:
 Understand terminology:
control statements,
counters, increment and
decrement statements,
Boolean expressions,
infinite loops, iterations,
arithmetic and strings and
determine precedence
 Labs: Income Tax
Calculator: code program
that calculates income tax
on employee input of gross
income and number of
dependents
 Modify program to ask user
if they want to run it again
(yes/no) and break out of
loop accordingly
 Run a given set of test data
through the program and
record the results
 Project 3-4: Calculate
Regular Pay and Overtime
Pay
 Again, modify so that user
can run multiple times by
answering yes/no at the
completion of the output
Strategies: Allow students to
make their own errors and give
them practice in solving them.
Require students to solve the
logic problems first – i.e. how
do you calculate overtime?
Then have them convert their
pseudo code into java code.
Resource: FJ Ch. 4
Assessments:
Unit Review Projects
 Project 1: Cube Surface
Area
 Project 2: Rectangle
 Project 3: Renting Videos
 Project 4: Bookstore
 Critical Thinking –
continuously prompts the
user until certain condition;
calculates totals
 Unit 5 Quiz
C5-C6
C1
C5
C6
6
(10-12)
nested loops, break
statement
 Construct various if and ifelse loops
 Construct While loops
 Construct For loops
 Understand the various
errors that occur within the
loops and be able to debug
 Be able to trace program
flow through the loop;
understand when the
counter gets updated and
how that affects overall
processing
Topic: Introduction to Classes and
OOP
 Create and Use Classes
 The Internal Structure of
Classes and Objects
 The Student Class
 Structure and Behavior of
Methods
 Scope and Lifetime of
Variables
 toString()
Objective:
 Understand terminology:
constructor, accessor,
mutator, instance variable,
encapsulation, information
hiding
 Design and implement a
simple class
 Understand the difference
between public and private
access in a class
 Understand how to declare
a method and declare
parameters in that method
 Write constructors, mutator
methods, and accessor
methods for a class
 First Quarter TEST
Strategies: Allow students to
develop debugging skills;
understand and code correct
logic (both syntactically and
content oriented), and
understand how to use various
data types and control
structures.
Resource: FJ Ch. 6
Assessments:
 Projects 1-2: (Student)
 Project 3: Fractions
 Project 5: Bank Acct
 Project 8: Rectangle
 TEST: Chapter 6
Strategies:
Be sure students are able to
construct a class based on the
specs of that class given to them.
Check for appropriate
representation of all variables and
methods.
C2-C3
C4
C5
C6



7
(13-14)
8
(15-16)
Understand how messages
are transmitted to methods
through parameters
Use instance variables, local
variables, and parameters
appropriately
Learn how and when to use
the toString() method when
an object is printed
Topic: Advanced Control
Statements
 Logical Operators
 Nested If Statements
 Nested Loops
 Testing Loops
 Verification of Loops
 Switch / Try-Catch
statements
 Design, Testing and
Debugging
Objective:
 Construct Boolean
statements using logical
operators
 Understand the logic of
nested If statements
 Construct nested loops
 Create test data that
adequately tests the code
 Construct query driven and
menu driven programs
 Format test and numbers
for output
 Handle number format
exceptions during input
Topic: Arrays
 Declare and initialize arrays
 Manipulate arrays
 Create parallel arrays
 Arrays and methods
Resource: FJ Ch. 7, Projects
Assessments:
 Project 1: Guess My
Number game
 Project 3: Grading Scale
 Project 5: Euclidean
algorithm
 Project 7: Perimeter and
area of a rectangle using a
range of amounts.
 Project 8-9 (as time
permits): various tasks
using words in a sentence.
 TEST: Chapter 7
C1
C5
C6
Strategies:
Students need plenty of practice
writing different types of loops and
conditionals. Make sure student
can hand trace the logic, as well as
prepare appropriate test data.
Resource: FJ Ch. 10, Exercises and
Projects
Assessments:
 Various exercises
throughout the chapter,
checking for understanding
C2-C3
C4
C5-C6
9
(17-19)
Objective:
 Understand terminology:
array, element, index,
logical size, physical size,
parallel arrays
 Declare 1D arrays
 Use initializer lists in
declarations
 Manipulate arrays using
loops and indices
 Create test data that tests
the boundaries of arrays;
write code to handle all
exceptions
 Define parallel arrays and
determine when they are
best used
 Work with arrays of
primitive data types and
reference variables.
Understand the difference
between the two.
Topic: Advanced Operations:
Strings, Arrays, & ArrayLists
 String Class and methods
 Linear Search
 Binary Search
 Selection Sort
 Insertion Sort
 Bubble Sort
 Insertions and Removals in
Arrays and ArrayLists
 2D arrays
 Using 2D arrays
 Use the ArrayList class
Objective:
 Instantiate string objects
 Terminology: immutable,
meaning strings cannot be
changed
 Use appropriate String
methods to solve problems
 Understand why a sorted




on manipulating arrays
Written Review Questions
Project 1: Even-Odd
Project 2: Greater than Avg
Project 6: Student Test
Scores
Strategies:
 Students need plenty of
practice manipulating loops
that work with arrays.
 Remind students that
arrays start with 0
 Remind student of the
importance of creating
relevant and thorough test
data
Resource: FJ Ch. 11-12
Assessments:
 Exercise 12.1 – searching an
array of objects for a target
object
 Exercise 12.2 – describe
behavior of a bubble,
selection and insertion sort
 Various projects at chapter
end: Tic Tac Toe, Golf
Scores, new method for
Sudoku, Magic Square
and/or Penny Pitch.
 TEST over Units 8-9.
Strategies:
 Be sure students practice
tracing through sorts and
searches to determine
efficiency.
C2
C3
C4
C5
C6
10
(20-22)
array can be searched more
 Explore videos of various
efficiently than an unsorted
search/sort methods and
array
be sure students can
 Understand the algorithms
explain how each one
of searching/sorting arrays:
works.
including linear and binary
search, and bubble,
 Review students’
insertion and selection sorts
understanding of adding or
 Write a method for
replacing elements in an
searching an array
array.
 Perform insertions and
deletions at given positions
in arrays
 Understand time
constraints of different
sorting/searching
algorithms
 Given different scenarios,
students should be able to
choose the most
appropriate sort or search
Topic: Recursion, Complexity,
Resource: FJ Ch. 13
Searching and Sorting
Assessments:
 Towers of Hanoi
 Recursion
 Many Queens
 Complexity Analysis
 Factorial
 Binary Search
 Fibonacci
 Quicksort
 Binary Search
 Merge Sort
 Quicksort
Objective:
 Merge Sort – including
 Create a recursive method
complexity analysis
to solve a problem
Strategies:
 Understand the difference
 Verify students understand
between recursive and
the concept of “recursion”
iterative solutions to a
 Verify that students can
problem
determine a quicksort vs a
 Understand and use the
merge sort
Merge Sort
 Be sure students can
 Perform Complexity
compare efficiencies in
Analysis on an algorithm
these sorts and the sorts
 Understand how to
already learned
calculate the informal
runtime of merge sort and
compare it’s running time
C2
C3
C4
C5-C6
11
(23-26)
12
(27-29)
to the other sorts already
learned
Topic: GridWorld (Parts 1-3)
 Experiment with a large
program
 Using classes
 Modifying classes
Objective:
 Run the case study and
analyze output
 Understand how the
development of a large
program came about by
reading the chapters of the
case study
 Observe and experiment
with the GridWorld case
study
 Understand the Bug class,
runner class, Grid Interface
 Extend the Bug class by
creating a specialized bug
to meet some new type of
bug requirement
Topic: More on Classes,
Inheritance, Interfaces,
Polymorphism and Collections
 Classes
 Inheritance
 Abstract Classes
 Interfaces
 Polymorphism
 Collections
Objective:
 Use inheritance to extend a
class
 Understand polymorphism
and override methods in a
super class when
appropriate
 Create and extend an
abstract class
Resource: GridWorld (pts 1-3)
Assessments:
 Exercises from within the
case study
Strategies:
 Read the case study manual
thoroughly
 Be familiar with all the
classes and interfaces
discussed
C5-C6
C7
Resource: FJ Ch. 11, FJ Ch. 14
C4
Assessments:
C5
 Create an abstract Shape
C6
class
 Project 11-2: Design a
hierarchy of classes for
vehicles
 Project 11-5: Design a class
hierarchy for Bank Accounts
 Pet Parade (2004 FRQ #2
from AP Central)
 Project 14-1: manipulate
text filenames
Strategies:
 Have students be able to
visualize the inheritance
hierarchy with pictures
 Teach advanced concepts

13
(30-31)
14
(32-36)
Create and extend a class
given class specifications
with the relationships
among the classes
described
 Implement an interface
 Recognize different
categories of collections
 Vocabulary: list, stack,
queue, set, map
 Distinguish between a
collection’s interface and its
implementing classes
Topic: GridWorld (Part 4)
 Inheritance
Objective:
 Use inheritance to extend
the Critter Class; make new
types of Critters
Topic: Review for AP Exam
 Review of all AP Computer
Science topics
Objective:
 Prepare for the AP CS Exam
by reviewing material and
taking practice exams
from Ch. 14 if time allows
Resource: GridWorld Case Study
(Part 4)
Assessments:
 Exercises from text
Strategies:
 Allow students to be
creative with their work
and show ownership
 Create different kinds of
critters!
C5-C6
C7
Resource: Previous FRQs from AP
Central; printed materials from
summer institute
Assessments:
 Practice Exams
ALL
C1 – C8
Download