[MWForum] Amazed.
Jay
mwforum@lists.mathcats.com
Tue, 7 Jan 2003 20:59:35 -0500
Hi Members
I am amazed at what a child can do (in terms of designing an interactive
program), and I am equally amazed and pleased with MicroWorld's product ...
MWPro. An excellent program, that allows one to quickly proto-type, design
and run a wide range of visual programs.
This past September, for my grandson's 11th birthday, I bought him (and
myself) MicroWorld Pro. I have been teaching him how to use MWPro primarily
through e-mail. (Made 2 or 3 visits to his home to get him started).
To be fair about this glowing testimonial, I must confess I did introduce my
grandson to MSWLogo programming, about a year ago. It held his interest a
short time. He progressed from drawing Squares to Decahedrons, Spirals, etc.
but the interest faded ... difficult to teach and maintain a child's
interest via only e-mail (few visits to his home). Needed more Bells &
Whistles ... that's where MWPro comes in.
My grandson loves fixing things, taking things apart, looking inside things
... he figured out how to customize and use MSWLogo's Pop-UP Windows before
I did! ... But his interest was fading. So as a change of pace (rather than
ask him to write more programs), I wrote a program with deliberate errors in
it, and asked him to fix it. ("Fix the houses" . I drew 3 incomplete houses.
The 1st house needed windows, the 2nd house had a crooked roof that needed
fixing, and the 3rd needed painting).
Rather than simply correct my erroneous code (as I expected), he wrote new
code to re-draw corrected images over my erroneously drawn houses. I'm
always surprised how different a persons solution can be!
After three small MWPro projects,
1. A Coordinate Smart Turtle,
2. How to talk to Text Boxes,
3. Fix the Houses,
I suggested he design a game called "Pick-up Sticks" ... a paper/pencil game
...
(I wrote a computer version of it on a Philco 2000 Main Frame Computer about
40 years ago).
I sent him an e-mail defining how the Pickup Sticks game was to work.
I had no further discussions with him about the game, and I had no previous
discussions with him about the "IF Statement".
(see below).
For Christmas (as a present), he sent me his solution!
(see below).
I am amazed what a child can do! (and how excellent a product MicroWorlds
Pro is!)
<<<<<<<<<<<< My e-mail to David >>>>>>>>>>>>>>>>
Hi David ...... November 25, 2002
Did you ever hear a "Yo-Momma-Is" joke?
Yo-Momma-Is ...........
Yo momma is so stupid it took her 2 hours to watch 60 minutes.
Yo momma is so stupid she sold her car for gasoline money!
Yo-Momma-Is ...........
Could also be Yo-Daddy, or Yo-Brother, or Yo-GrandPa (Oh!. No! . Not GP's !)
Well so much for jokes. Now let's get on with some serious design stuff.
For our 1st game project we are gonna play a "pickup sticks game". Where we
have a bunch of sticks and 2 players. We agree to pickup 1, 2, or 3 sticks
when it's our turn. We alternate turns & agree who should go first. The
object of the game is:- the last person to pick up the last stick, loses. (A
variation of the game could be .. the last person to pick up the last of the
sticks, wins).
Now I know how smart you are and you can probably design and build this
whole game all by yourself, but we are going to do it differently. It's
something like playing the piano without taking piano lessons. I don't want
you to develop bad habits.
So, I will specify what the game will look like and how it will operate, (I
get to name all the sliders, buttons, and textboxes) and you will build it.
(In the future, when we start a Second Game Project, I'll just say what kind
of game I want, and you will design it and build it.).
============================================================
We will break this game up into 5 design stages.
1st stage:- Very basic operation. Just two real players called "Guest" and
"David". No error checking. Just get the mechanics of the game to work.
[sticks-1-00.mw2]
2nd stage:- Add some error checking to the game. Be sure a player does not
take more sticks than is allowed. Check when there is a winner.
[sticks-2-00.mw2]
3rd stage:- Add some Bells and Whistles and fancy stuff. [sticks-3-00.mw2]
4th stage:- "Guest" versus dumb "Computer". Teach the computer how to play a
dumb game. Where the computer does not know the winning strategy, but at
least can play the game. [sticks-4-00.mw2]
5th stage:- "Guest" versus smart "Computer". You learn the strategy of how
to play a winning game and teach the computer how to play a smart game.
Also, add the last stick (win or lose) variation capability.
[sticks-5-00.mw2]
When you finish all this you can go to Turtle Logo College!
======================================================
Need:
1 slider [slider1] to establish the number of sticks to start with.
3 buttons [m1, m2, m3] to control whether to pickup 1, 2 or 3 sticks.
1 textbox [text1] to display the number of sticks in play
1 textbox [text2] to display the name of whos turn it is. "Guest" or "David"
1 button [who.1st] to establish who goes first (should switch [text2] player
's name with each click)
1 button [reset] to do what ever is need, like:- move [slider1] into
[text1], and move "Guest" into [text2]
Remember for 1st stage:-
Don't worry about [text1] going negative.
Don't bother to check for a winner. Just get the basics working.
Note:
The "who.1st" button procedure may require use of the ifelse command.
(We never discussed IF statements)
Try the following little example to see how the ifelse command works:
(also check MWPro's Vocabulary Help)
example:
to TEST
make "player1 "guest
make "player2 "david
settext2 :player1 ;;; or ;;; settext2 :player2
ifelse (text2 = "guest)
[show [the textbox has GUEST]]
[show [the textbox does NOT have GUEST]]
show [that's all folks]
end
An alternate FUTURE design could be to draw pictures of the sticks, and
control their appearance and disappearance, rather than than use a text box
to show the number of sticks left.
<<<<<< end of my e-mail >>>>>>>>
P.S.
I'll post David's solution in a few days.
(This will give Members of MicroWorld Forum a chance to write their own
solutions, if they care to.)
Regards
J (also known as GP)