ShmoopTube
Where Monty Python meets your 10th grade teacher.
Search Thousands of Shmoop Videos
AP Computer Science A Videos 108 videos
AP Computer Science 1.2 Program Development. Which of the following is correct?
AP Computer Science 2.3 Classes and Objects. Which of the following is correct implementation of the Country class?
AP Computer Science 2.3 Program Development. What is correct implementation of the Emperor constructor method?
AP Computer Science 1.4 Program development 8 Views
Share It!
Description:
AP Computer Science 1.4 Program development. Which of the following is not part of an effective application of functional decomposition?
Transcript
- 00:03
And here's your shmoop du jour brought to you by a bunch of
- 00:06
hooligans who crashed the boat party they just barged in...consider the [People partying on a boat]
- 00:11
following class declaration........
- 00:16
which of the following is not part of an effective application of functional
- 00:21
decomposition....... alright here we go well the idea of functional
Full Transcript
- 00:29
decomposition is to simplify our class by creating a hierarchy of sub classes [Sub classes appear out of a box]
- 00:34
containing data fields and methods relevant to that specific class well in
- 00:39
this case boat should become a superclass with only data fields and [Boat sinks in the ocean]
- 00:43
methods that are universal for all types of boats
- 00:45
Choice A does this exactly simplifying boat so that it is a superclass for
- 00:51
other classes choice B also gets us one step closer to [Man moves up a step]
- 00:55
functional decomposition by removing data fields that should be in its
- 00:59
subclass. Choice C doesn't look quite right we want all boats to be named because [Boats in the harbour with names]
- 01:05
this is a property on all boats, we should declare it in the parent class boat but
- 01:10
let's come back to this in a sec. Choice D also helps with functional decomposition
- 01:15
we want one generic print function in the boat class but every subclass should
- 01:20
override it to customize it to the specific boat type finally choice E
- 01:24
describes one of the most basic actions to achieving decomposition each subclass [Sub classes sitting at their desks]
- 01:30
should have data fields and methods that are specific to it so that just leaves
- 01:34
our correct answer as C, next time learn about the admiral who was against
- 01:39
buying a new hat he was afraid of capsizing [Admiral falls overboard]
Related Videos
AP Computer Science 1.2 GridWorld Case Study and APIs. What is the direction of the actor?
AP Computer Science 1.4 Standard Algorithms. How many times will mystery be called for mystery(n) for n > 1?
AP Computer Science 2.3 Classes and Objects. Which of the following is correct implementation of the Country class?
AP Computer Science 3.4 Inheritance, Abstraction, and Polymorphism. Which of the following will satisfy the conditional if statement for boo, str,...
AP Computer Science 4.2 Standard Algorithms. What kind of algorithm is the following?