Sunday, November 5, 2017

Computer Programming Courses for Middle School Children

As my daughter is in middle school, I recently reviewed courses designed for middle school children. Eight years ago, there was limited curriculum for middle school children.

Today, there is a wealth of curriculum. Instead of developing your own curriculum, I suggest using existing curriculum that a professional has built. code.org has a good list of curriculum for middle school kids. Although I'm not using the curriculum on any of the lists, the offering at CodeHS looks interesting. There are introductory courses for both Python and JavaScript. The JavaScript course is designed for 9th graders.

Pythonroom also looks promising. The video looks like they have a great vision, but I'm a bit concerned that they have 5 thumbs up and 2 thumbs down at the time I looked at it.





I'm still experimenting with different mixtures of Python and JavaScript. I recommend starting with Python as it is easier and the structure helps with learning. My daughter also feels that Python is easier than JavaScript.

If Python is better for learning and teaching, why I am teaching her JavaScript? Well, JavaScript is everywhere. It's used to quickly distribute web applications, build mobile applications with PhoneGap and build server applications with node.

Here's what I ended up doing:


  1. started with Python and Pygame using my drills and used the drills for a month
  2. taught HTML, CSS, and basic JavaScript, including JQuery for about a month. Not using any type of graphical animation such as HTML canvas or any framework
  3. Used the JavaScript game development framework Phaser for a month, including the Making your first Phaser game tutorial
  4. went back to Python and Pygame for another few months and used RAPT Pygame to run the apps on a mobile phone
  5. went back to using JavaScript canvas for a month, which is where I am right now. I'm planning to go back to Phaser in about 2 to 4 weeks.


Examples from Lessons


This game was built entirely in Python and uses RAPT Pygame to run it on an Android mobile phone. It's running on a Moto G 3rd generation. Age 12.
Teaching objective: loops and game levels



The test below was made with Unity and some pictures she took at the local Stanford museum.
Teaching objective: 360 image photography and basic 3d asset usage



This one is done entirely in Python. Age 12.
Teaching objective: association of attributes for an object. Did not actually use objects.




This is another Pygame example. Age 12.
Teaching objective: if statements


This one is done in JavaScript.
Teaching objective: Use of arrays.



Sunday, March 5, 2017

Phaser Girl JavaScript Lessons For a Middle School Girl


I'm working with girl coder on new drills based on Phaser and JavaScript. In each lesson, I sit by coder girl and watch her type in the same drill 10 times.

The philosophy for Phaser Girl is to take the simplest possible code snippet and build from there. Programming concepts are not explained until after the drills are started.  The idea is to dive in, start typing, and the concepts will arise over time.

This structure came from watching my son learn karate. Since his dojo (classroom) was 25 minutes away, I would often stay in the dojo and watch the class.

There are three components to teach kids karate:

  1. kihon (fundamental: punch, kick, block)
  2. kata (form: collection of kihon)
  3. kumite (sparring: application of kihon and kata)

For Phaser Girl, the equivalent is:

  1. syntax: conditionals, loops, variable assignment
  2. drills: the basis of Phaser Girl
  3. projects
Within this framework, I focus on drills. The syntax emerges from the drills.

Repetition

I originally started with a target of 5 reps. During the first lesson, Blank Screen, I increased the target repetition to 10. The objective is for coder girl to be able to go through the drill without looking at reference material and without encountering a syntax error by rep 8.

By drill 6, Cursors, each rep was taking 5 minutes, pushing the total lesson time to 70 minutes. I gave coder girl a 5 minute break after rep 5.

Practical Application (kumite) Example

Level 1, simple project. 40 lines of code total.




Drill (kata) Example


Fundamental (kihon) Example