
John Resig: Redefining the Introduction to Computer Science at Khan Academy - spicyj
http://ejohn.org/blog/introducing-khan-cs/
======
powrtoch
It's hard for me to imagine learning Javascript as your first programming
language. It's always felt kind of crazy and bizarre to me (especially when
you try to do anything requiring more than 20 lines of code), but I think a
lot of that is just failure on my part to shake off the paradigms I'm used to.
A generation of coders who are actually trained from the start to _think in
Javascript_... almost scary honestly, but in a good way. We need more John
Resigs pushing the web forward :-)

~~~
JVIDEL
If you ask me this has more to do with JS becoming the _lingua franca_ of web
development and less to do with making programming as easy as possible.

Case in point, recently some chick from highschool asked me where she could
learn to code, so I pointed her to some Scheme tuts, nothing too complex since
she requested something as easy as possible.

....then she writes back asking if "this is what jquery uses". I say "no", she
gets upset and ask me "what the hell is this for then?"

Long story short: for a lot of people out there is not about learning how to
code but _learn-X-to-do-Y_ no more no less...

~~~
cshesse
If you're not learning how to code to do something useful with it, why learn
to code?

~~~
hackinthebochs
There's some of us out there who enjoy coding for its own sake. Coding is a
pure form of problem-solving. It doesn't necessarily matter what the problem
is you're solving, just that you get a certain intellectual satisfaction out
of the process. I must be one of the few that coded linked-lists and string
containers in high school instead of silly text games :)

~~~
jason3
Fuck you.

------
thesash
Learning tools like this would have saved my teachers a lot of headaches if
they were available 10 years ago.

As opposed to the classroom model of: [lecture -> assign work -> grade &
return with static feedback], students can actually play with the subject
matter _during_ the lesson, instead of turning pens into projectiles or
doodling in their books because they're bored to death (not that I know
anything about that). Then they get immediate feedback, whether right or
wrong, by seeing how the instructor would have solved the problem. That kind
of hands on learning, where the student learns through their own trials and
errors is much more fun than sitting through a lecture that has to accomodate
the varied learning paces of a classroom of 20+ students.

The video posted here unfortunately focuses on the live editing aspect of the
app, but you can see the interactive lesson function more clearly in this
early prototype video[1].

This kind of interactive learning is the same thing that Sebastian Thrun is
working on at Udacity[2]. For all the promise of making university courses
available for free online, I think this is the truly disruptive stuff going on
in online education, because it's way beyond just filming lectures and
throwing them online, it's a fundamental leap forward for education.

[1] <http://www.youtube.com/watch?v=nvaaude_1hk> [2]
<http://www.youtube.com/watch?v=75TP3hoPA8U>

~~~
richcollins
_play with the subject matter during the lesson_

Kind of removes the need for a "lesson" and teacher, in favor of a facilitator
that can go around and help those learning to discover things they hadn't
considered.

~~~
robryan
Sounds like what is happening in the lower year levels these days.

------
dons
Some similarities with Felleisen's work teaching programming to early high
schoolers,

\- <http://www.programbydesign.org/>

Those folks have tons of data on what works, what doesn't.

I get a bit of a NIH feeling from this effort, that I hope is unfounded.

~~~
rabidsnail
Having everything run in the browser is a _huge_ win, because it allows
students to share what they've made with their friends. Post to facebook "Look
what I made", which includes the source and makes it easy for others to modify
it and share that themselves. Viral loop!

~~~
soegaard
It is possible to use Scheme in the browser too:

    
    
        http://www.wescheme.org/

~~~
rabidsnail
Yes, but it's not possible to run Dr. Scheme in the browser. So there would
still have to be a fair amount (ie almost all) of reinvention.

------
scottrblock
I think a small, beautiful detail lost here is John Resig's career path. As
the creator of jQuery, he probably had his choice of which sexy SV start-up to
go work at. He chose a non-profit that's aiming to fundamentally improve his
country's education. Pretty admirable if you ask me, and perhaps more
importantly, a slice of hope, that if one desires to, he or she can use his or
her time to change the world for the better.

------
msg
Interesting. I have shown my son the Logo turtle, but hopefully this will make
even more sense to him. I was looking for a way to expose him to Processing
but unsure where to begin. It's obvious now.

We are home schooling and always looking for new and interesting stuff to do
with him.

Thank you, John.

~~~
archon
Thank you for being willing to teach your son programming. I was homeschooled
with a programmer for a dad and I guess it just never occurred to him to teach
me himself. I discovered programming on my own in late high school, but I
would have loved it when I was younger.

~~~
joelhooks
We homeschool, and I've always tried to present my kids with programming
concepts. Scratch, JavaScript, Python, Ruby, Squeak, and a few others. My
oldest has shown intermittent interest, but he's had plenty of exposure. He
will definitely be able to say "I started programming when I was 8" - and I
assume that when/if he catches the bug, he will know where to look and
what/who to ask.

------
karpathy
Don't miss the link to Bret Victor's lecture on responsive programming:
<http://vimeo.com/36579366> . I found it to be very enjoyable and it further
shows what is possible with this paradigm. [minutes 2-23 are most interesting
and relevant]

~~~
agentultra
While I enjoyed that video, it came to me as a bit of surprise that this style
of programming is being "rediscovered."

Anyone remember Morphic, Squeak, Lisp, etc? Emacs?

Lively Kernel is pretty darn cool too.

I'm not saying it's bad, I think it's cool that this style of programming is
making a come back (and about bloody time I suppose).

The only thing I'm not certain of with this course is actually calling it,
"Computer Science." Perhaps that's because I tend to agree with those who
question whether it is indeed a science at all. However after watching a few
videos and trying some of the exercises it seems to me to be a great way to
learn how to program.

------
bpierre
We are working on a similar project (programming education), but in a
persistent and multiplayer environment. It’s more like a live game framework
which allows to learn JavaScript, or just to have fun!

Everything is programmable: the display of a bot (Canvas 2D Context API), the
buttons used to to control it, the interactions between the bots, etc.

<https://github.com/bpierre/modul.io>

------
ilaksh
This is massively badass. I think this may be the best tool out there for
learning programming.

One issue I am having here in Chrome in Ubuntu on my computer is that some of
the videos are giving me minor playback problems where some visual features
are not visible. For example, in the intro to drawing tutorial the rectangle
seems to turn into a line because three of the sides are not visible. This is
probably just what I get for using Linux though.

Anyway, I was wondering: have Mr. Khan and the rest of them put any thought
into how the new interactive programming environment might be applied to
learning math or other concepts taught by Khan Academy besides Computer
Science? Like specifically taking some of the math or other lessons and
presenting applications to tweak that would demonstrate those concepts. Maybe
lessons in those other areas could sometimes include a link to a programming
experiment.

Also, other question: are there any plans to try to cover a broader range of
computer science or maybe even software engineering topics, for example things
like Objects/Classes, components, unit testing, QA, feedback loops in general
or for example between the developers/analysts and the users or between the
developer and his test suite?

------
crusso
This is very exciting. I was just looking around this past weekend for a way
to introduce my 10 and 13 year-olds to programming concepts. I want them to
understand more about the computer than how to play warcraft, watch youtube
videos of pandas, or even make slide presentations.

My one daughter is going into 8th grade and has had a total of two half-
semesters of "business and computer science" where the most they do is to play
around with PowerPoint and Excel. Computers are so integral to every-day life
now. It's positively disgraceful that every child shouldn't be educated on
what they are, how they're built, how they work, how to program them, etc.

------
hanibash
Probably like many others, I learned to program first by developing web
applications. The mass of information and multiple moving pieces frustrated me
almost to the point of quitting. There are probably many people who did quit
when introduced to programming this way.

This CS learning platform brings programming education back to its simple
roots, back when your first program was as simple as drawing a circle in
BASIC. It also leaps it forward, borrowing ideas from Bret Victors
responsiveness talk was brilliant and I hope sets a precedent for programming
education moving forward.

I really admire what you've done, Mr. Resig and the Khan Academy team!

------
johntb86
I wonder if they've added any help for transitioning out of their sandbox. I
know when I first learned programming, one problem I had was taking what I
learned in the classroom on Apple IIs and transitioning to using GW-Basic or
QBasic at home. Transitioning from a browser-based sandbox to editing HTML and
real files would probably be even worse. It might be nice if there was an easy
framework they would let people download to help them create things in a more
normal environment, so they don't get stuck and give up at that point.

~~~
schrijver
I very much agree… In fact a large part of learning to code is not much grab
abstract principles as it is getting accustomed to the eco system: how code
relies on other code, how it is organised on files, and how it gets uploaded
to the internet. It would be great if this site provided the opportunity to
download a set of html and js files that re-implement the result of the
students… a great starting point also for a teacher to talk about these
issues… and a way for students to walk outside the garden when they feel like
it…

------
vph
These are good entrepreneurs and programmers, and they are using great tools,
but I don't think they are qualified to say they are redefining teaching basic
Computer Science.

Interactive platforms and approaches have been constantly introduced by CS
educators to teach introductory programming. Educators are very aware of the
value of interactivity and reactivity in teaching and learning. The only new
thing here is the utility of cool new tools equipped with latest web-based
technologies. Further, their approach is limited to programming, which is a
large part but not the only approach to Introductory Computer Science. For
example, they can't touch approaches such at MIT or Rice (I think), among
others, which employ cool physical robots to teach coding, thinking,
programming and robotics.

So this is not so much redefining, but rather a little enhancing CS education
with cool tools.

------
jonahkagan
Awesome stuff. John Resig, if you're in here, can you give any details on the
challenges of instantly updating the Processing sketch? I can just wait for
the blog post, but I'm really curious.

Also, what components exactly are you planning to release open source? The
other work in this area that I've been able to find is very tightly coupled to
the rendering library (d3 or PJS). Is the Khan Academy system open to
alternate rendering libraries?

~~~
kinleyd
Yeah, real awesome stuff, John Resig! Your follow through on Bret Victor's
'Inventing on principle' is mind blowing. I'm getting my kids on it right
away. Thank you.

------
look_lookatme
This is cool and I think Javascript is a perfectly suitable first time
language, but I don't think it's ideal. Too many ways of doing things, too
many code organization and programming styles... it's going to be confusing
for people moving beyond the courses.

Still it's better than c++ or java.

~~~
phleet
Hey - I'm one of the interns that worked on this.

I have my own reservations about JavaScript the language, but after seeing
what John had built when I started, I believe that this is undoubtedly the
right way to go.

If we wanted to use another language to accomplish similar goals, the options
would be:

1\. Run the code on the server. This dramatically increases latency,
introduces more security concerns and would dramatically increase our costs as
this would inflate our server load dramatically. Really, its the latency here
that makes this a no-go. As you use the number scrubber, it's re-executing
several times a second, and that's just not going to work out with client-
server communication (even with websockets).

2\. Run a different language that compiles to JS and runs in the browser. As
it stands, the overhead of doing this is also too much. It would be shipping a
compiler or parser down to every client. CoffeeScript may be the most
reasonable option there, but it has many of the same warts as JavaScript
anyway. Any parser/compiler needed introduces an extra step in the pipeline
and would inevitably reduce responsiveness.

While JavaScript the language certainly has its problems, it's what it lets
you do that counts here.

~~~
chromatic
_Run a different language that compiles to JS and runs in the browser. As it
stands, the overhead of doing this is also too much._

Not at all--it takes some work, but especially if most programs are less than
a few hundred lines long, the overhead is far less than you think!

------
th0ma5
He mentions the responsive design being really hard, and that was something I
couldn't quite articulate to myself when I saw that talk a while ago... the
ideas Bret Victor presented, only a handful of them are general purpose. I
don't see how one could develop the timing examples he had, for instance, in a
way that makes sense outside of his specific work on his 2D platform game.

------
rabidsnail
Little nitpick: Why make the draw event handler a magic variable instead of a
function which takes a function?

Ie:

    
    
        var draw = function() { point(random(0, 400), random(0, 400)); };
    

as opposed to

    
    
        onDraw(function() { point(random(0, 400), random(0, 400)); });
    

AFAICT there aren't any other variables that side-effect based on what you've
assigned to them.

~~~
phleet
Granted this is certainly not JS best practices, but following best practices
was not our goal here.

Explaining variable assignment is much simple than explaining callbacks and/or
higher order functions.

On a more practical note, this is the convention that processing.js uses, and
thats what we're using to render the canvas.

------
crag
Best part of the intro video:

"Welcome. I'm super excited about computer science. it's my favoriate thing in
the world... except for pot".

QFT.

~~~
rhc2104
I believe she says "pie", and not "pot".

~~~
crag
You sure about that? I heard pot. Maybe I just "wanted" to hear pot. I'll
listen again.

~~~
UK-AL
I don't think it would be wise for a kids education site to reference pot.

~~~
crag
Ok ok.. I still hear "pot".. but that's probably my "New Yorker ears" tuning.

You are right though; since it's aimed at high school, I doubt it's pot. ;(

~~~
pitchups
If it sounds like "pot", doesn't matter if he really said "pie"; chances are
many kids are going to hear "pot" too unfortunately.

------
archivator
This is not unlike Bret Victor's work - <http://vimeo.com/36579366> . Do watch
the video, if you have an hour to spare, it's a beautiful demonstration of
"programming by tinkering."

------
jameshsi
This is great. I volunteered at Maker's Faire earlier this year at the Scratch
booth and a lot of parents were wondering what some possible next steps could
be for their kids who were interested in learning more about programming. It
felt a little weird suggesting Khan Academy videos, but with this project I
think the transition to deeper CS concepts is a lot more seamless for those
who are curious

------
bhb916
I sat my 5-year-old daughter down in front of the first drawing tutorial today
(Introduction to Drawing). I let her watch the video, then asked her some
questions to test her comprehension. Before I could too many questions out she
blurted "I want to build a house," and off we went.

I learned a few things:

1\. We seriously need to work on her typing skills. We practice typing once a
week but I think I need to increase that.

2\. I need to go out and buy a smaller mouse to fit her hand.

3\. She immediately understood functions and parameters, which, honestly, was
all I really wanted her to get out of this.

4\. The sliders are _critical_. She has never seen a coordinate system, but
the sliders allow her to play around with location without completely
understanding what the numbers represent.

5\. At this age, she was engaged because she could draw things (she had a
house worked out in about 15 minutes, which was also the limit of her
attention span). I'm not always a fan of gaming things up to make them more
palatable, but it definitely worked here.

------
VikingCoder
I am done with all of you so-called "hands-on people" who don't give people
real tools to use.

The XO (One Laptop Per Child) and now this.

Please stop giving people tinker-toy environments with tinker-toy problems
that have nothing to do with the real world.

If someone's not motivated to learn, yes, they may need this kind of hand-
holding. But if someone genuinely wants to learn to program computers for a
living, this is - in my opinion - not what they need at all.

Drivers Education is taught in a real car, not in Mario Kart on a Wii. I'm
sick of the Mario Kart version of computers being spoon-fed to otherwise
intelligent people as though it has anything to do with reality.

I learned to program using Turbo Pascal. I was not so far removed from reality
that everything I learned was almost completely useless. I have not given this
much attention yet, but so far, it feels completely useless.

PLEASE correct me if I'm wrong.

~~~
VikingCoder
"Reducing the complexity of getting started down to zero will result in more
people learning."

Yes, but you're removing NECESSARY complexity, in order for them to learn
something barely worth learning.

"I feel that purely textual coding environments (or coding environments that
favor textual output over visual output) serve as a highly uninteresting
introduction to programming."

There are people who get to use non-textual coding environments, and there are
people who get to work with very visual outputs. I feel that by giving them
these tools, you've castrated their ability to understand anything meaningful.

"Obviously, right now we’re not teaching very much in the way of traditional
Computer Science content,"

Yeah, approximately none of it.

"We decided that it was much more fruitful for us to tackle the most
challenging problem that exists with Computer Science education first: Getting
people excited about programming."

Of the people who are AT ALL interested in learning about programming, I have
encountered exactly zero of them who aren't already excited about it. Why do
you think that GETTING them excited is the "most challenging problem"?

I absolutely applaud the effort, and I sincerely wish you success.

I just personally think you're doing it all wrong.

~~~
yusefnapora
> Of the people who are AT ALL interested in learning about programming, I
> have encountered exactly zero of them who aren't already excited about it.

How is this tautology at all helpful? Of course the people who are excited
about programming are excited about it. For every one of those, how many view
computers as entertaining magic boxes? Most non-programmers I know regard
programming as a kind of impenetrable dark art. There is such a monumental
disconnect between "Hello World" and "I can do whatever I want!" that most
people just assume that they'll never be able to achieve any meaningful
result. Being able to create something visually interesting that you can share
with your friends is a big motivator, and I think you're too quick to deride
it.

Also, I don't get why you view this as something "barely worth learning." The
"real world" doesn't run on Turbo Pascal anymore, and Javascript, like it or
not, is a big part of modern programming. Do you really think it will be so
difficult to translate skills acquired generating interesting games into
skills that can be used in a modern web shop?

Anyway, you're welcome to your opinion, I just personally don't understand it.
Luckily for people that share your opinion, there are plenty of traditional CS
resources all over the web and elsewhere to learn programming in the "real
world." For those whose "real world" consists of playing games and wondering
how they work, this might just be the thing that motivates them to look under
the hood.

~~~
VikingCoder
You call it a tautology, but my point is that Resig claims that "the most
challenging problem that exists with Computer Science education" is "Getting
people excited about programming." I do not think that is the most challenging
problem that exists with Computer Science education.

He doesn't just claim that it's a problem with Computer Science education. I
agree that it's a problem, and I value tools that try to help.

No, he's claiming it's "the most challenging problem." I strenuously disagree.

I think the most challenging problem with Computer Science education is
retention. I know a bunch of people, personally, who for whatever reasons, got
excited about programming - they wanted to learn. They had their own intrinsic
excitement for programming, and wanted to move forward.

A few things hindered them, in my opinion: they had no idea how to get
started, and even if they did get started, they soon lost interest because it
wasn't obvious to them how the tools they had access to were ever going to get
them anywhere they wanted to go. Given a goal - say, how do I make a game? -
they did not believe there was a finish line they could cross.

I can accept the criticism that I'm too quick to deride it. I'm sure this is a
valuable tool for some people. Given the people that I know, who already were
motivated, I do not believe this tool will help them at all, and that
disappoints me because I had hoped for more.

I think it's barely worth learning because I know hundreds of professional
software developers, and I know approximately two of them who got to play with
HTML5 Canvas at work - myself and a friend at another company. Both of us did
it in our spare time, for fun, because our bosses would never have asked us to
do it. If you know more people who are professional HTML5 Canvas developers,
then your anecdote trumps mine.

------
sethish
It is disappointing that KA launched their Computer Science program not long
after making their website closed source[0]. Doubly disappointing because of
open-education projects that were using the software platform to do free
education projects in Brazil[1] and Portugal[2].

[0]:
[https://khanacademy.kilnhg.com/Auth/LogOn?ReturnUrl=/&nr...](https://khanacademy.kilnhg.com/Auth/LogOn?ReturnUrl=/&nr=)
[1]: <https://calenglishbr.appspot.com/> [2]:
[https://uc3m-ka.appspot.com/login?continue=http%3A%2F%2Fuc3m...](https://uc3m-ka.appspot.com/login?continue=http%3A%2F%2Fuc3m-ka.appspot.com%2F)

~~~
TheSilentNumber
It's really sad. They were never really concerned with being truly free &
open. They just were "open" in the wishy-washy way that when you do anything
online for free, you can call it open and get lots of support.

~~~
schrijver
So why are these remarks getting downvoted? BTW, could someone provide links
with more details, i.e. what was closed, this still appears pretty open:
<https://github.com/khan/khan-exercises>

~~~
shardling
I think they're getting downvoted for being incorrect.

I can't find any info about KA moving to closed source.

------
bwlang
I "watched" the first lesson or two. I think they've missed an opportunity to
tighten the watch-try-watch loop with the student. This tachnology seems like
it would support a mode like "here is how you draw a box" then "you try
drawing a box that overlaps with the box on the screen". Maybe they do that
later. I hope so, otherwise I think they're missing a great opportunity for
engagement. Even without that level of interaction, I still plan to try this
out with my children. Really impressive.

------
daviddaviddavid
This looks really great. One criticism is that this style of graphical
programming is overwhelmingly of a mathematical bent. Granted it's quite basic
arithmetic but still, you open a code sample and you're confronted with a
bunch of numbers and mathematical expressions.

My worry with this is that there are many, many youngsters out there who are
intimidated by math but who would absolutely love to write code. This is
especially worrisome since such a huge amount of coding involves no math at
all.

~~~
jeresig
In our experience thus far we've found that students are far less intimidated
by the numbers/math when they're able to directly manipulate the results. When
they can tweak the numbers with minimal ramifications and instantaneous
feedback they can easily intuit what the numbers are attempting to do. Working
with young kids we definitely found that they were comfortable in this
environment even after minimal introduction.

------
warmfuzzykitten
Seems clear they are teaching Programming and not Computer Science. There's
nothing wrong with that, but they should be upfront about it.

~~~
ZeroGravitas
Quite far down the long post they say:

 _"One question is obviously: How much “Computer Science” do we actually
teach? Obviously, right now we’re not teaching very much in the way of
traditional Computer Science content, we’ve placed far more focus onto the
platform and feel that a lot can be gained from just what we’ve already built.
We’re still very early on in the production of content and will be producing
much more, of increasing complexity, over the upcoming weeks and months.

We decided that it was much more fruitful for us to tackle the most
challenging problem that exists with Computer Science education first: Getting
people excited about programming. If we can get people excited about
programming, and build (or point them to) the resources they need to learn
more then we will have been successful.

Eventually I think we’ll work to effectively replicate the materials one
typically finds in a “Computer Science 101″ but in a way that is far more
engaging and self-paced than what you would find at a traditional
university."_

------
suyash
I feel this approach is more confusing than clearer specially for beginners.
Without giving a primer to the proposed languages (seems like they are using
javascript and css), I feel a newbie would get more confused and leave the
site after a few minutes.

------
sciurus
Anyone have a cached copy? ejohn.org is returning a 500 error.

~~~
iyerrag
[http://webcache.googleusercontent.com/search?q=cache:http://...](http://webcache.googleusercontent.com/search?q=cache:http://ejohn.org/blog/introducing-
khan-cs/)

------
gadders
I understand why they only want the latest browsers, but it sucks that I can't
look at it in my spare time at my locked down corporate (IE8) environment.

------
eranation
Love it, Who is the presenter in the videos? the voice sound really similar to
Vi Hart or is it just me?

~~~
Encosia
Sal Khan and John Resig are narrating the video.

~~~
eranation
I know, I talk about the actual videos, e.g. this one
<http://www.khanacademy.org/cs/intro-to-drawing/848372201>

~~~
jeresig
They are narrated by Jessica Liu (as mentioned in the blog post).

~~~
eranation
Thanks, she is doing an amazing job

------
Rickasaurus
Programming is not computer science.

------
bazookaBen
tried it. The greatest takeaway for me is being able to edit the code and see
changes live.

------
scoith
Was there something wrong with the old definition?

