[racket] Universe Examples

From: Matthias Felleisen (matthias at ccs.neu.edu)
Date: Thu Aug 11 10:14:09 EDT 2011

On Aug 10, 2011, at 6:57 PM, Felipe Cocco wrote:

> Hello everyone,
> 
> I am teaching a 10-week after-school intro to programming class to a small group of high-schoolers, focusing mostly on creating simple worlds. However, as soon as I mentioned that the language provided an easy way to implement servers and ways for different worlds/programs to interact, the students asked if we could tackle a multi-player game project. 
> 
> I looked at the bouncing-ball example provided in the documentation but I was wondering if anyone would be willing to share some examples of more elaborate multi-player universe programs, since this will also be my first time trying to implement such a program. I saw in the mailing list archives references to a battleship example but I couldn't find any code for it. Any help would be greatly appreciate.


Felipe, thanks for your interest. 

My first response is a concern. I honestly doubt that a Universe game is within reach of high school students who have 10 weeks. Well, in principle yes, but it means sacrificing a lot of data structures and a lot of program design. I'll think about a task that's within reach. 

The second response is also a concern. As much as it would be cool to say that your Nth graders wrote a distributed game, it sounds like you wish to teach via copy-paste-modify. I don't think your students would really learn much that way. 

Finally, here are some links from courses at NEU that use universe, though none of them is suitable for a 10-week introduction at a normal high school: 

  http://www.ccs.neu.edu/home/matthias/107-f08/Assignments/8.html
	Problem 8.1 is about designing a distributed hangman problem 
	doable with strings 

  http://www.ccs.neu.edu/home/matthias/107-f09/Assignments/9.html
	Problem 9.1 is about designing a chat room 
	doable with strings 

  http://www.ccs.neu.edu/course/cs2510h/Assignments.html
	This course is our second course, also taught in Racket.
	Some of the assignments are about distributed Universe programming, 	
		though it uses the Racket class system. 
	The lecture notes may inspire you too. 

If I have time, I will put together the chat room as an example that is accessible from the 'string' chapter in HtDP/2e. If this is of interest, I recommend assigning the exercises in HtDP/2e that are about editing strings (insert, delete, etc). They lead up to the chat room problem from above. 

-- Matthias




Posted on the users mailing list.