Thursday, August 7, 2008

Emergent Properties

I remember first learning about emergent properties from Elliott Sober at the University of Wisconsin. Of course back then the focus was on emergent properties in biological systems.

Like any great concept, however, it easily applies itself to other areas, like education. I've pretty much made a career out of harnessing the emergent properties of a classroom--those seemingly unpredictable results of 25+ students interacting as a group--let's call it the "personality of the class at hand."

Well, I'm learning a lot about emergent properties in web hosting. Taken apart, I feel like I can grasp PHP, MySQL, and an application like Moodle. Host all of them on a Debian Linux server and you'd think it was all black and white.

Enter emergent properties. Suddenly the web host's PHP configuration and Moodle decide that I can't upload files. Or rather, I can, but then I can't access them--which is not a good thing on a Moodle class page. :-( I'm trying to find the problem, but spending five hours on this has only made me want to just delete the whole mess and start over. At lease I've got Wordpress working correctly for the new migrant/ELL blog I'll be hosting.....

Wednesday, August 6, 2008

Baby, You're the Greatest!

Spent most of this morning working on Alice. The image you see is from the classic FirstEncounter scene that is used in the Learning to Program with Alice book.

What's so cool about Alice is how advanced you can make your programs become. Rather than merely doing the scene as asked for in the text, I introduced for loops and turned the robots motion into a much more complex and realistic set of instructions. [He now lifts up his back middle leg, walks on his other four legs, then lowers the back middle leg down for support after walking.] That would not have been easy to do without Alice's awesome interface, which lets you click, drag, and drop various methods of the various objects. Oh, and I added the penguin just as a shout out to Tux.

Last year I used Alice while teaching the IMP Math unit All About Alice, which teaches students exponential functions. It was remarkably easy to have my students program the examples from the text into scenes using Alice, so that when Alice doubled here size ten times in a row, students got to see just how big that would make her.

Alice is a free gift from Carnegie Mellon University. If you haven't played around with it yet, give it a try.

Tuesday, August 5, 2008

Designing programs in Java


I've done my fair share of complaining about Java, and I still believe that the AP Computer Science exam should be in Python--a more flexible language with cleaner syntax and the ability to use Object-Oriented design if appropriate.

Truth is, though, that Java has a special appeal to my obsessive compulsive tendencies. There's something cozy about sitting down to write a relatively simple Java program. With Python I'm tempted to just start writing--and the development time in Python really is super fast. With Java, though, you need to plan things out ahead of time a little more. Of course that's a good idea in Python, too, but it's not enforced in the way Java enforces program planning.

Since I only have a week or so before school starts, I'm practicing my chops and staying sharp by writing a few programs here and there. Today I decided to write a Java version of the classic Hi-Lo Guessing Game. Rather than just starting to code, however, I thought about the program in detail beforehand, and made a few design choices that would help make the program something I may use in my programming classes (as an example of design). Let me elaborate.

The basic Hi-Lo simply has one playing guessing a number between two set values, like one and one hundred. The other player guesses a number, like 42. The first player than says "Higher" or "Lower" depending on the secret number. You know the game.

What I came up with, however, were three classes to use in a program:

1. ComputerPlayer
2. HiLoGameEngine
3. StatsKeeper

Now, each of those classes will have specific attributes and methods that they are responsible for. Using a procedural approach it would just be the one program and the human user, with the program responsible for all three roles that I've delegated to individual classes. Why do this? Because it's good design. Suppose I want to improve the AI of the ComputerPlayer class. Rather than tweak that class, I can extend it with a CleverComputerPlayer class, or even a CheatingComputerPlayer class. The StatsKeeper class may be reused in another program in the future--in a tic tac toe game, for instance. You can see the possibilities of Object Oriented Design in the long run; software can be reused for other applications.

Bringing this into the classroom will be fun. One of the weaknesses in the AP Computer Science curriculum, I think, is that it focuses on solitaire coding. In reality, especially in open source, but also on development teams, a programmer needs to know how to work on a team.

By the way, in my program the computer and human players switch roles and compete in a series of games, with the StatsKeeper recording all the results.

Sunday, August 3, 2008

Reflections on the 2008 AP Java Workshop at CMU

Last night I flew home from the 2008 AP Java Workshop that I had been attending all last week at Carnegie Mellon University. Although I'm happy to be home, I'm also a little sad that the workshop is over. (Yes, I do appear in these pictures of the workshop--not sure why it's called a picnic, though.)

Leigh Ann Sudol
ran a great workshop. In particular, I was interested in her views of women and minorities in computer science, as my programming classes have a large number of female and/or minority students.

Don Slater
gave us some top secret looks at Alice 3.0, which was perhaps the highlight of the workshop for me. Alice is really a special program, and having EA come on board can only help make it even better. Although I would prefer Alice to be a full open source project, I think including the EA models from the Sims 2 game is probably a very good thing.

Randy Pausch passed away a couple days before the workshop, so CMU had a somewhat somber feeling throughout the workshop. He will be missed. I also got to meet Wanda Dann, another main member of the Alice team.

All the presenters at this year's workshop were excellent. I was especially amused by the humor and energy that Dave Feinberg brought to mix. The world needs more teachers like Dave.

Now the hard part: applying what I've learned. Our school is no modern technological wonder. I've already found out that adding 15 computers to my classroom is just not possible, according to the district electrician. That leaves me either using a mobile lab of laptops in my classes (hoping the batteries hold out), or taking my classes into a nearby computer lab that is anything but cutting edge. The irony here is that more and more the advances in open source are making it possible to reach students like my students, and yet there is always something that seems to hold them back, like when I asked to have Alice running for my students last year and it never happened.... :-( Teachers who use open source software must have their own installation privledges, something I don't have at all in my own classroom--except for on the IBM-donated MESA laptop that I have running Ubuntu.

On the brighter side, however, I have used Dreamhost and set up plenty of space for a new school web page and more than enough room to house all the STEM teacher's Moodle class pages. The computer programming club also has free use of my site for their own web page, along with any students in the club that want to host on my domain:

www.FutureSkyline.com

Not a commercial site, but EVERYONE thinks ".com" nowadays. Anyway, you can watch the site develop over time, if you'd like. Right now it's pretty sketchy.

In conclusion, it was a good week. I was especially ammused by the discussions I heard of two very deservedly hot topics: Python and Ubuntu. From the short time I got to talk to these other computer science teachers, I'm convinced that in almost every case a Python user is a Python fanatic, and an Ubuntu user is an Ubuntu fanatic. I heard of more students using Ubuntu than teachers using Ubuntu, but teachers are slow to change.

I also must say that I have a new level of respect for Macs, after using Macs exclusively the whole week. May have to get me one of those someday to complement all my Linux boxes.

Friday, August 1, 2008

Praise for Ubuntu from a Java Education Expert

Cay Horstmann is almost a legend in the AP Computer Science field. While reading his blog recently, I came across this paragraph:

"Ubuntu is a great platform for software development. We covered a lot of ground in a short amount of time, and the students who used Ubuntu instead of Mac OS X or (gasp) Windows were way more productive. We particularly loved the feature where you type in a command (such as aclocal) and Ubuntu tells you to run sudo apt-get install automake if the command isn't yet installed. What could be better?"


The AP Java Workshop here at Carnegie Mellon is winding down. I got a sneak peak at the new version of Alice last night from Don Slater. I'm trying to get my school to be a pilot school for the upcoming version this next year.

Wednesday, July 30, 2008

Last one in the lab is me... :-(

This AP Java workshop has been a lot of work and a lot of fun so far. I can only say positive things about the workshop. I mean, after teaching ten or so years and going through grad school, well, you go through your share of experiences that can at best be described as "so-so". Not this workshop.

About the worst thing here so far has been
  1. My Java syntax
  2. My Java API knowledge
  3. My familiarity with all the various IDEs for teaching Java to students.
So tonight I stayed overtime, and it was time well spent. Python is much more natural for me to code, but I'm really learning some good habits here this week. So far the discussions of OOP have been very comprehensible for me--a heck of a lot better than they would have been back when I first encountered OOP.

Ate at a little cafe this evening. Pita bread with hummus , black bean soup, and iced coffee.

Monday, July 28, 2008

AP Java Workshop Report #1

I'm in Pittsburgh!

Got in yesterday, flying from Mountain Time to Eastern Time, so of course last night at midnight I was wide awake. Getting up at 6:30 this morning was a bit tough. Tip: set alarm clock far a way from bed, so you have to climb a chair and desk to get to it.

The photo on the left is the Tower of Learning at nearby University of Pittsburgh. I have this thing about tall buildings--I always want to go to the top, by stairs if possible. That's on my list of things to do before leaving Pittsburgh.

Some notes from the AP Java Workshop.

1. Discussed the implications of the upcoming elimination of th e AP Computer Science AB class (APCS A will remain).

2. Covered three very cool applications for teaching Java (and one even has a Python version):
--Jeliot
--Jeroo
--Javabat

3. Had a sub for lunch. Maybe I should have one of those big sandwiches before I leave Pitt.