Zero to Java in Internet Time

Download Report

Transcript Zero to Java in Internet Time

Zero to Java in Internet Time
David Davenport
Computer Engineering Dept.,
Bilkent University, Ankara 06533 Turkey
email: [email protected]
Introduction
• Programming classes (mandatory!)
–
–
–
–
computer literacy
basic programming
object-oriented systems
event-driven GUI’s
• Desire
– get students up-to-speed quickly
– justify by focusing on engineering skills
What to Teach & Why
• Engineers today should
–
–
–
–
be technically competent
be able to communicate & work in team
be confident in locating & applying knowledge
be motivated to follow tech. & continue learning
• Programming as a vehicle
– form of communication, done in teams
– complex systems, mistakes cheap!
What to teach & Why
• Engineering relies on methodologies
– Only apparent for large problems!
• Teach
– OOP first?
– Structured programming first?
• Which language
– C/C++, Pascal/Delphi, etc.
– Java (consistent OOP, complex?, Internet)
Course Organisation
• First semester CS101
– conventional lecture/lab (text-based progs.)
– Robo & Jrobo… (concepts)
• Second semester CS102
– reduced lecture/lab (GUI progs.)
– Design project… (eng. skills)
• Software Quest
• InSites
Design Projects
• Semester-long group project
• Group & project selection
• Organisation
– Four stages: requirements, GUI,
detailed design, implementation
– submit report, make presentation, rewrite
• Use commercial IDE
• Tap enthusiasm, Internet, …
(don’t tell, they learn)
Tools: Robo
• Robo: little robot with pen…
• Basic commands: f(x), r(x), l(x) & p
• Interactive start…
• Reflection - need a easy life!
• Introduce
– comments, methods, parameters...
– top-down design, pre/post-conditions
• Design, not experiment (right-first-time)
Robo Examples
f(100)
r(45)
f(50)
r(30)
f(150)
r(120)
f(150)
r(120)
f(150)
r(90)
rect(a,b)
f(a)
r(90)
f(b)
r(90)
f(a)
r(90)
f(b)
r(90)
Tools: Robo
• The Robo environment...
Tools: JRobo
• OOP - natural view & facilitates reuse
• Examples - person, car, tv … & Robo
• JRobo class & use
• Adding methods & properties
• Composition - wallets & cellphones
• Inheritance & Polymorphism - scale & colour
• The JRobo environment...
Jrobo Examples
f, r, l, p
x,y draw
heading
f, r, l, p
f’
f’, r, l, p
rect, getDofM
x,y draw
heading,
dofM
rect
x,y draw
heading
getDofM
dofM
payout
recieve
cash
owner
Tools: JRobo
• The JRobo environment… (a full Java IDE)
– hide syntax at beginning, enforce good practice!
Concluding Remarks
• Use programming to teach engineering skills
• Tools help clarify concepts
• Projects help develop skills
– Napster & ICQ clones, physics & optics
workbenches, online games, shops & dating...
– Variable quality (focus more on design)
– but energy, enthusiasm & work evident!
• Java & Internet motivate
• Extra time & effort, but worth it?