Download presentation
Presentation is loading. Please wait.
Published byNoah Atkinson Modified over 9 years ago
1
Program Design in Scheme
2
Program Design The purpose of software is to provide a useful service -- to help someone else do his job better, improve his life. Good design is more difficult than good programming. A software engineer with good design skills has more potential than a good programmer. automatic code generation (based on design documents) will gradually reduce programming How do we learn good design?
3
Learning Program Design Think and practice. Learn from others (read, join a project) Scheme is often used to teach program design because it encourages small, modular programs. How to Design Programs http://www.htdp.org/ Bruegge, Object-Oriented Software Engineering: Using UML, Patterns, and Java Lethbridge, Object-Oriented Software Engineering: Practical Software Development using UML and Java 219341: Software Specification and Design
4
Scheme Example: Movie Theatre profit: the theatre's profit is revenue minus cost revenue: ticket sales times ticket price cost: fixed operating costs plus pay-per-view costs sales: depend on ticket price (and movie, of course) What is the purpose of this program? What are the inputs we have control over?
5
Scheme Example: Movie Theatre profit: the theatre's profit is revenue minus cost revenue: ticket sales times ticket price cost: fixed operating costs plus pay-per-view costs 50,000 Baht/day + 20 Baht/view sales: depend on ticket price (and movie, of course) demand * ( 1 - sensitivity*(ticket price - 50) ) Moviedemandsensitivity "block buster" 15000.04 "hit"10000.06 "good"8000.06 "average"6500.08
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.