• Archive
  • RSS
  • Ask me anything

Daniel Stucke

FizzBuzz CodeYear Fun #schoolstech

With todays announcement from Mr Gove it seems a good point to reflect on my first steps on a year long coding journey. I spent my Tuesday evening completing the first week of lessons on the brilliant CodeYear. It took me about an hour and a half and was a great little introduction to Javascript. First week covers defining variables, basic arithmetic, and moves on to if/then/else/while statements.

It’s an interesting learning model, there are hints at each stage and I didn’t find myself stuck on too many occasions. If you teach ICT or Maths then I’d thoroughly recommend you take a look at it. It was quite a challenge and I’ll be interested to see how far students could get without a teacher to help them. If they do get stuck, some good Googling skills would help them find a way forward pretty quickly. It’s not a replacement for a skilled teacher thought, but that’s a conversation for another post!

The final bonus challenge is to write a FizzBuzz program that writes out a set of consecutive numbers, but replaces multiples of 3 with “Fizz” and multiple of 5 with “Buzz” and of course, multiples of both with “FizzBuzz”. It’s a great little challenge that the Maths teacher in me loved!

I’ve been encouraging staff and students at school to join me on this journey so it’ll be interesting to see how many are up for the challenge.

Here’s my final FizzBuzz code in case you’re interested or stuck:

// Ask user how far we should Fizz Buzz for
var Total = prompt("How far shall we fizz buzz?");

// for the numbers 1 through to Total,
for (i=1; i<=Total; i++) { 

  // if the number is divisible by 3, write "Fizz"
  if ( i % 3 === 0 ) { 
    // unless the number is also divisible by 5, then write "FizzBuzz"
    if ( i % 5 === 0 ) {
    console.log("FizzBuzz");
    }
      else 
        console.log("Fizz");
  }

  // if the number is divisible by 5, write "Buzz"
  else if (i % 5 === 0 ){
    console.log("Buzz");
  }

  // otherwise, write just the number
  else {
    console.log(i);
  }
}

Has anyone written this in a neater, purer way? I’d love to see it if you have.

EDIT:

I have to include this, a solution in a tweet by Martyn Colliver:

    • #Code Academy
    • #codeacademy
    • #coding
    • #programming
    • #ictcurric
    • #ict
    • #maths
    • #Fizz Buzz
    • #codeyear
    • #Javascript
    • #technology
    • #education
    • #teaching
  • 4 months ago
  • 13
  • Comments
  • Permalink
  • Share
    Tweet

Learn To Code

Code Academy have set up Code Year. A lesson a week that over the course of the year will teach you how to code.

Slate suggest each lesson will run to about 5 hours. Which is a hefty commitment. But I’ve signed up and will be encouraging learners at school to do the same. With our big push on Computing and the future ICT curriculum changes on the horizon, it’s about time I can walk the talk!

Source: Slate

    • #coding
    • #Code Academy
    • #codeacademy
    • #programming
    • #national curriculum
    • #ICT
  • 4 months ago
  • 5
  • Comments
  • Permalink
  • Share
    Tweet

Arrington invests in Code Academy

I spotted the excellent Code Academy a few weeks ago. And it looks like I wasn’t alone. It’s received a huge round of funding including from Michael Arrington:

What really excites me about Codecademy is that you can learn almost anything this way.

All I can think of is how if this was around when I was in college I may have actually learned calculus this way. I got a B in that class but I can clearly remember at the time being completely lost, and anything I did learn is now permanently wiped from my brain.

It’s an interesting take on this form of learning and it looks like Code Academy is going to follow in the footsteps of Khan Academy et al in promoting learner led online instruction.

I think much like Khan Academy, this certainly has a place and is a fantastic resource for people to teach themselves some key concepts and basics until they’d inevitably be better off with a real teacher helping you out, setting challenges and interacting with other learners.  It’ll be interesting to see what comes from the ability for users to create their own Code Academy lessons.

What do you think?

    • #code
    • #codeacademy
    • #programming
    • #education
    • #learning
    • #elearning
    • #KhanAcademy
    • #Khan Academy
    • #Code Academy
    • #technology
    • #Arrington
    • #Michael Arrington
    • #Crunchfund
  • 7 months ago
  • 20
  • Comments
  • Permalink
  • Share
    Tweet

Code Academy

Love this website that teaches you the basics of how to code. Have passed on to our new Computing GCSE class.

    • #code
    • #coding
    • #programming
    • #Computing
    • #CodeAcademy
  • 8 months ago
  • 50
  • Comments
  • Permalink
  • Share
    Tweet

About

Avatar Assistant Headteacher from Manchester, UK. This is a space for my thoughts on education, technology and more. Has for now taken over from my old blog at www.mrstucke.com

Me, Elsewhere

  • @mrstucke on Twitter
  • SHSELearning on Youtube
  • Mr Stucke on Flickr
  • mrstucke on Delicious
  • danielstucke on Pinboard
  • danielstucke on Last.fm
  • danielstucke on Foursquare
  • Google
  • My Skype Info
  • Linkedin Profile

Twitter

loading tweets…

Following

I Dig These Posts

  • Photo via minimalmac

    Typerighter is a new application that I have been testing for a while. As the developer is a close personal friend of mine and willing to listen...

    Photo via minimalmac
  • Link via parislemon
    Don't Let The Door Hit You On The Way Out Of Google Reader

    Google is ripping out the underlying social stuff in Google Reader — stuff that never...

    Link via parislemon
  • Photo via scienceisbeauty

    This problem! From Calculus By Michael Spivak we suffer on first course. I’ve used it many times and few people are right, even people of...

    Photo via scienceisbeauty
  • Post via willrichardson
    Welcome to My New Space Online

    After 10 years of blogging, I’ve decided to move my efforts away from Weblogg-ed over to here, my new site on Tumblr.

    Post via willrichardson
See more →
  • RSS
  • Random
  • Archive
  • Ask me anything
  • Mobile

Creative Commons License
This work by Daniel Stucke is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
Based on a work at danielstucke.com.. Effector Theme by Carlo Franco.

Powered by Tumblr