Introducing Blair McHugh – Teacher of Digital Technologies

Licensed under Creative Commons

Licensed under Creative Commons

Recently I took the opportunity to sit down with Mr Blair McHugh, our new teacher of Digital Technologies at St Andrew’s College and discuss his previous experiences and vision for the subject. What became apparent was Mr McHugh’s passion for the subject and how his approach to teaching programming aims to dispel the common misconception of a sole programmer working in a darkened room eating pizza!

Prior to joining the staff at St Andrew’s, he had taught for 9 years at Burnside High School and before that at Cashmere High School. Importantly, however, he has industry experience with Fujitsu NZ primarily in networking and infrastructure and it is these skills he aims to impart to students at the College.

A coding language is just a tool – if you’ve not solved the problem before you begin the actual coding,  then you’re probably not going to solve the problem.

Mr McHugh will be teaching students the Python coding language, however as the above quote suggests, there is significantly more to this subject than just learning one of the many programming languages that exist these days. The steps students are encouraged to follow are:

  • Plan – understand what the requirements of the job are, ask the right questions and formulate an approach to solving this before you start coding. Analysis like this early on helps to ensure future success in the project.
  • Code – once you have fully analysed the problem and planned an approach, only then attempt to write some code.
  • Test – execute the code and see if it works!
  • Review – check how it has all gone
  • Repeat – go back to the planning and analysis to see what may need to be improved, re-work the code accordingly, and test it out. Keep repeating this process until you have it working and the problem is solved and the key outcomes from the planning stage are met.

One of the key messages Mr McHugh has to remind students of is the need to avoid “programming on the go” as this almost invariably leads to wasted time:

Time is the biggest and most precious resource available to students. There is little cost in ‘real’ resources when churning out code, but time spent aimlessly coding is too important to waste

To achieve an Excellence in Level 3, students need to demonstrate real efficiencies in their code – there should be no “blind corners or dead ends” – and the easiest way to avoid this is effective planning and regular reviewing of the code.

To further enhance the students ability to plan efficiently, he promotes a very open, collaborative environment where students are not just expected to participate and inter-relate with each, they are required to. This is supported by the banning of headphones in class – students can not be an individual silo separated from the rest of the class. The rationale behind this is that increasingly in the workplace, programmers need to be talking to stakeholders, clients, fellow programmers and communicating effectively to all of these individuals.

Sec_T1

The Term 1 2016 DPR Value of “Honesty” works very well in Digital Technologies

Whilst discussing this, Mr McHugh pointed out how well the Term 1 DPR Value (Developing Positive Relationships) worked in his class. He expects students to be honest when they’ve struck a problem with their coding or analysis and be able to ask other students for input.

Key Competencies

The Key Competencies from the NZ Curriculum

 

Consequently, the Key Competencies from the NZ Curriculum play a major role in his classes, in particular  Participating and Contributing and Relating to Others as students interact and collaborate together. In the words of Mr McHugh:

 

No one codes alone in a silo in the real world – being part of a team and coding on a bigger project is a critical skill to learn in school.

To further support this, students practice sitting around a table, asking questions of each others’ projects. Asking the right sort of questions is an essential part of problem solving and developing critical thinking skills. Along with these skills is the continued importance of a strong mathematical foundation to be a successful programmer.

Too often, students do not think maths or physics are necessary in coding, however to start doing advanced 3D graphics a strong grasp of matrices and geometry is critical:

Students can still do 2D platform style games, Angry Birds etc, without strong maths. However, it’s the 3D graphics in games like Halo that really spins their wheels and attracts their attention … BUT you need great maths ability to do that sort of thing.

Following on from the work of Mr Phil Adams, Mr McHugh will continue the lunchtime Code Clubs for those students who are not taking Digital Technologies as a subject.

I’m really looking forward to seeing some of the projects that students will work on this year and hopefully writing about them on this blog.

Code Clubs @ StAC

2015 has seen two Code Clubs start at St Andrew’s College with Mr Phil Adams running one in the Secondary School since the start of the year and Mrs Vicki Pettit alongside Mr Wilj Dekkers starting one in the Preparatory School during Term 2.

Preparatory School:

CodeClub_LogoThe Preparatory school are using the resources provided via Code Club Aotearoa and there are around 20 students that attend regularly, within which there is a reasonably even break down of beginners and intermediate coders with 2-3 advanced coders.

The resources on the Code Club Aotearoa website are perfect for beginning and intermediate students however, Mrs Pettit is exploring options for the more advanced students and in what areas they can possibly start to apply their skills e.g. robotics, Raspberry Pi projects and possibly entering them into the Canterbury Core Education Digi Awards. The other pathway recently made available to these Prep students is Monday lunchtimes with Mr Adams in the secondary school code club.

Secondary School:

In Term 1 2015 Mr Adams started the Code Club for students that were interested in learning more about programming and were prepared to attend during their lunchtimes. His motivation was twofold:

  1. There was currently no option in the Junior curriculum (Years 9-10) for programming which means when students can take this at Year 11 they are often being introduced to the concepts for the very first time.
  2. There were a number of very keen students who did not have an avenue for support in their coding unless they persevered by themselves and were essentially self-taught from online.

Whilst there was an initial surge of enthusiasm from students, this settled into those that were committed, keen and prepared to give up a lunchtime to learn more. Having looked at the formal code clubs that existed (such as Code Club Aotearoa above), Mr Adams also reviewed online offerings such as Code Academy and Code Avengers which were useful, particularly Code Avengers which aligns with the New Zealand NCEA standards. Ultimately, however, he decided that students could continue to access these in their own time and that the focus of the Code Clubs at StAC would be slightly different.

python-logoThis alternative was to focus on teaching the students the very basics of Python so that they could create their own scripts and taste success early on. The reason for Python was quite simple as Mr Adams explains:

As a text based language the syntax is not complicated and it is very logical. Therefore, the learning curve would not be too steep for our new students. An alternative language such as C or C# would be too challenging for them to start with.

As students learnt the basics, Mr Adams focused on creating a team culture where students could learn from each other: the beginners seeking help from more advanced students, who in turn could reinforce and demonstrate their understanding of Python by teaching the beginners. Through this approach, it is hoped the Code Club will become self-perpetuating and independent with a positive and interactive culture.

With a few weeks of the basics out of the way, the goal became to progress students with the introduction of logic into their coding e.g. a basic guessing game such as this one:

An example of a number guessing game from Hana

An example of a number guessing game from Hana (click to download the Python script)

Hana, who created the above script, had the following to say about Code Club @ StAC:

I used to do coding at my old school, Selwyn House. There, it was a big thing and we did robotics and Hour of Code. The code club at StAC is super fun. Mr Adams is a really good teacher and he always lets us figure out why our code hasn’t worked. 

Coding a basic guessing game is not too difficult and yet it can easily be extended with the introduction of more logic that would require students to be able to calculate the average number of guesses it takes people to correctly guess the number each time. To support this extension, Mr Adams has created numerous tutorial videos on his YouTube channel that students can access, such as this one on how to create a list within a list using Python:

Paper, Scissors, Rock by Louis (click to download the code)

Paper, Scissors, Rock by Louis (click to download the code)

Louis, who also attends the Code Club @ StAC, created a game of Paper, Scissors, Rock in Python. Like Hana, he is also enjoying attending:

I am attending the Code Club because I enjoy coding in my own time (I also have done some robotics coding and other things) … 

I have learned things with Mr Adams (We are doing python at the moment, I have many other languages including: HTML, CSS, PHP, UNIX Terminal, Command Prompt, and JavaScript)

Next Steps:

Mr Adams has some clear next steps identified for the students in the Code Club, with the ultimate aim getting them to work collaboratively on a project together, all contributing code to a repository such as GitHub. This would enable replicating a “real world environment” where multiple people all work on much larger projects. This mirrors the message from Old Collegian Claudia Pottinger, who shared her experience as a Google Intern writing code in Python last summer. It is apparent that some of the students in the club are already thinking that far ahead, such as Jack who is in Year 9:

I go to code club because it is something I feel will benefit me in the future, and it is my intended career path. Computer programming is one of my passions, it is something that I enjoy doing in my own time.

It is extremely fun, learning new things and being able to help others who do not know so much.

A project I just finished recently was the year 12 internal exam, where you make a program in python that allows a user to select, order and store different pizzas with a range of flavours and prices.

I feel that in the future Programming will be a large part of nearly every job.

Jack's Pizza Ordering script (click to download)

Jack’s Pizza Ordering script (click to download)

Another idea to extend the students is to introduce activities from Project Euler – a website that describes its motivation as being:

The motivation for starting Project Euler, and its continuation, is to provide a platform for the inquiring mind to delve into unfamiliar areas and learn new concepts in a fun and recreational context.

To complete the activities on the website, students will need strong mathematical ability but also programming skills. One example from this website that Mr Hilliam, Maths and Statistics teacher at St Andrew’s, has used with his students is to write code that identifies the sum total of all prime numbers under 1000.

With keen students in the secondary school, along with increasing numbers of students coming through from the Preparatory and other feeder schools, providing an avenue for students to learn coding at St Andrew’s College is essential.