Uploaded by ADLJ -

Unit 3 (1)

advertisement
Gloassry:
Entity:
is a logical or physical object in real world of the probelm that has attributes and
interacts with other objects
Relationship:
is a connection type between two or more entities in real world that describes the
nature of their interaction (i.e. object A own object B).
Pre-Test
1) One main advantage to Pattern Recognition is that it allows us to solve
seemingly diverse problems by a single algorithm
ANSWER: True
2) The vehicle object is an example for abstract object
ANSWER: True
3) Decomposition means breaking a problem down into a number of subproblems
ANSWER: True
4) Abstract can be represented in terms of models like entities
ANSWER: True
5) Answering the question of: What information is unnecessary in order to
remove it, is a part of:
a) Decomposition
b) Abstraction
c) Recognition
d) None of the above is correct
Post-Test:
1) Decomposition is used to remove details such as what product is being sold,
what it tastes like, where the stand is
ANSWER: False
2) Pattern Recognition means looking for similarities among and within
problems
ANSWER: True
3) Models often hide details of the reality they represent
ANSWER: True
4) Relationship represents the core concepts of the system while entity is a
connection that relates entities in the system.
ANSWER: False
5) In three sentences like:
I have three sliver cars - I have five silver suites - I have three silver tables
then the use of a general form like: I have…….silver …… is an example for:
a)
b)
c)
d)
abstraction only
both abstraction and pattern recognition
decomposition
programming
Assignment:
1) Write a pseudocode to control the game of Noughts and Crosses (Tic-TackToe)
Hint: here is the beginning of the pseudocode (logical steps)
1. game is started
2. begin loop:
2.1. prompt player to choose a square
2.2. if chosen square is not occupied, then put player’s symbol in
that square
2) Abstract a general procedure for adding and dropping courses
Discussion Board:
Read about abstraction in programming and then compare with abstraction in
computational thinking
Download