On Abstraction: Making Recyclable Programs

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 6

On Abstraction

Making Recyclable Programs


Ideal Program Division

Control,
Data
UI

Algorithms
Source:
Wikipedia
The restaurants client orders food

The chef receives orders and then


prepares them

and the waiter takes food matching


a clients order and serves it.
UML
<<Interface >>
Participant
----------------------------------------------
+ Position getMove(Player, TicTacToeBoard)

Human Computer
---------------------- ----------------------------------------------
- MoveEvaluation getMoveInternal(Player, TicTacToeBoard)
+ Player getOtherPlayer(Player)
+
MoveEvaluation
----------------------
+ Position bestPos
+ Player winner_when_minimize_opponent
UML

TicTacToeGame
-----------------------------------
- Participant player1
- Participant player 2
- TicTacToeBoard board

TicTacToeBoard <<Interface >>


----------------------------------- Participant
A lot of stuff. ----------------------------------------------
Ill spare that for now. + Position getMove(Player, TicTacToeBoard)

Human Computer
---------------------- ----------------------------------------------

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy