7 ms·
I too remember QBASIC with a lot of nostalgia, but surely Python is a better choice for introducing kids to programming today. name = input("what's your name
by taylorfinley 8y ago
I too remember QBASIC with a lot of nostalgia, but surely Python is a better choice for introducing kids to programming today.
name = input("what's your name?")
if name == "Noah":
print "you're the best!"
else:
print "you're the worst"
- guitarbill 8y agoThat's my sentiment exactly. I wish I'd had Python back in the day; especially the IPython REPL or Juypter notebooks. Both are excellent for hacking around, and immediate feedback.
- AlexeyBrin 8y agoTry to make a game or draw a circle in IPython, see how simple it is.
- gnud 8y agoimport turtle t = turtle.Turtle() t.circle(100)
- bartread 8y agoMy recollection is hazy, as I didn't use it much, but this struck me immediately as somewhat similar to LOGO back in the 80s.
- AlexeyBrin 8y agoOK, so I'm seven years old, I take your code and write it in my Jupyter notebook. Press run and I get half a page of errors with something about TclError: no display name and no $DISPLAY environment variable. I also have questions: What is import ? Why do you need to write turtle 3 times ? Why do I have to write t.circle ? This is boring, I better play Candy Crush on my phone. Compare your code with the QBasic equivalent: screen 13 circle (50, 50), 100 Another nice thing about QBasic is that the code is checked after each line and in case of error it shows you a clear error message.
- justinator 8y agoOK so I'm 7 years old. My parents are my parents, so I've got constraints you would give a child who sometimes wets the bed and can't always put all their own clothes on. I've got a bunch of paper and crayons. See you in a couple of hours, cause I'm just gonna draw. (or is childhood that different, now?)
- meheleventyone 8y agoUrrm, seven is quite old in respect to doing something like programming. I was writing (quite rubbish) BASIC on the ZX Spectrum at that age in the late 80's. No easy error messages and a single book to help. My own four year old no longer wets the bed and can easily dress herself when she can be convinced too.
- DanBC 8y ago1 in 10 children still wet the bad at age 7.
- dragonwriter 8y ago> 1 in 10 children still wet the bad at age 7. Which mean 9 in 10 don't. Not that, in any case, wetting the bed is actually in any way anything but a distraction in this discussion.
- oldcynic 8y agoAt under 7 years old my daughter was doing surprisingly fancy things in MS paint. Including finding features we didn't even know Paint had. "Daaaaaaad, crayons are boring, can I use the computer?" (I think there's a few minor differences) :)
- TomMarius 8y agoIt was (for some people) that different 20 years ago, at least from what I remember from my own childhood.
- digi_owl 8y ago> import turtle That to me is the ongoing problem with picking up a programming language these days, figuring out all the available libraries and which of them i need to load to get closer to my goal.
- guitarbill 8y agoI guess text adventures aren't as fashionable or exciting any more :'(
- Koshkin 8y agoIn my experience, JavaScript is (much) better suited for teaching kids programming than Python: it only takes a few minutes for them to go from nothing to being able to use plain HTML+JS and create a simple interactive application; after an hour or so of having fun, the shroud of mystery of coding disappears completely, and it's now all about creating something great, like a game. They usually find Python kinda boring by comparison, and more complicated.
- Drakim 8y agoPlus, it's super motivating when they can put their HTML+JS file on some free host and show it off to friends.
- nurettin 8y agoSwitch to a graphics mode and draw an angled line on the screen using Javascript. You will end up having to learn: the basic HTML5 template, canvas element, a turtle-like drawing language. In qbasic, SCREEN 12 LINE (50,50)-(100,100)
- 8bitsrule 8y agoThat way they will also learn that - once they use anything else - impressive things have never been so gloriously easy to do ever since. Javascript is good at many things ... but: There are countless examples of stuff in LEGO - fun stuff - that would take 10 to 100 times as much code to pull off. If possible at all.
- coldtea 8y ago>In my experience, JavaScript is (much) better suited for teaching kids programming than Python Only because of its connection to web display. Not because of the language's syntax or qualities.
- pasta 8y agoI think Processing (Java) is much better because it visualizes what you program in an easy and fun way. The Youtube channel The Coding Train is also great for this. It might be personal but coding with easy graphic output is very fun imho. Much more than Javascript alone when (as others commented) you need to learn HTML and canvas at the same time. I learned programming in (q)basic because of the line and beep functions.
- taeric 8y agoWhat are you hoping to prove with the example? That folks that know and understand many of the idioms of programming can easily read this? Not to mention it does invert many of the things that people coming to it will want. Consider, you want to tell the computer to ask for something. Once it has an answer, put it in a spot. name = input("what's your name?") That goes the other direction. You start with what you want to store, and then you turned the input into a function. Of course. Contrast with the BASIC. INPUT "What's your name"; name$ You began with what you want the computer to do, input something. You did have to learn "input", but you had to learn that in both. So, it is a wash. There are the odd semicolons. I'd imagine that took some effort. I'm not going to defend basic as a paragon of programming. But I don't think there is an easy answer. There are tradeoffs. BASIC was the answer in the past, as much because it was free and installed in a lot of default locations as anything else. There are alternatives now. None as widespread as Javascript, as much as the saddens me, personally. It is probably the best choice for people today.
- raarts 8y agoOk, so explain what an editor is, how to invoke and exit it, explain files, and how to run python programs. Also, indenting.
- eli 8y agoIndenting is no weirder than having to number your lines. But yeah, you'd ideally want to set up an IDE.
- gameswithgo 8y agoi don't think you had to number your lines in qbasic
- taylorfinley 8y agoThis is really a weak argument. Is running code from a jupyter notebook harder than: I installed QBasic on my son’s 11” HP Stream today, having to hack a DOSBox manual installation. Is pressing the run button harder than pressing the F5 key? Explain DOS to a seven year old, versus explaining "this is an app we can download."
- MagnumOpus 8y ago* Indenting is a good way to help explain loop/branch logic anyway. * Editors are not necessary for beginners - just like disk I/O was unnecessary in the times of the C64 BASIC. Create a bookmark to any of the many online jupyter servers (e.g. [0]), or install Anaconda with a shortcut to a local jupyter notebook. [0] https://mybinder.org/v2/gh/ipython/ipython-in-depth/master?filepath=binder/Index.ipynb https://mybinder.org/v2/gh/ipython/ipython-in-depth/master?f...
- dragonwriter 8y agoClassic BASIC both has less language to learn and teaches more about how things work. And line numbers, as much as they suck for real programming, are an awesome hack that lets your REPL be a line editor, letting you do all your work in the REPL, so you don't have to learn an IDE or working with an editor plus a (graphical or text) shell.