Learn How to Program Using Any Web Browser
The language is suitably light and simple, the book well-structured and broken down into easily digested chunks. The order in which concepts are introduced is fairly traditional for a language tutorial: first we get types, variables and statements, before moving on to conditionals, loops, and functions, followed by arrays and objects before finishing with event-driven programming. Davis' decision to leave string handling till last seems a little perverse and personally I would have introduced functions earlier.
My real complaints about this book centre on the abstract nature of the discussion. There are very few real world examples that could be useful to anyone. The best you get is a version of "Rock, Paper, Scissors" in Chapter 3, and an 'auction' application. The book would have been improved dramatically if the end result of your study was a few things you could actually point to.
I also have a complaint about the target audience for this book. The web page for the book at the publishers states that "The target reader is likely a twelve- or thirteen-year-old, who is just starting to get curious about what makes a computer work -- or an office worker who has been using computer applications for years, and would like to spend some time delving deeper into what makes them tick." Most adults and even teenagers don't want to 'learn how to program' as much as they want to learn how to use a tool to perform a task. If your tool is JavaScript, then it's almost certain your task is related to building web pages, but this gets little real attention from Davis. For even younger students, this book totally lacks anything to hold their attention -- the lack of real-world examples hurts here.
I also take issue with the title: this book doesn't really teach 'programming' much at all. It certainly teaches you to write JavaScript, but where are the sections about the real lessons of programming, such as top-down vs. bottom-up design, or breaking a task up into chunks? Even debugging has little coverage -- a single thirty-page chapter, half of which is specific to JavaScript or the throwing and handling of exceptions. Since the work of Papert and others at MIT twenty-five years ago, we've learned a great deal about how to teach programming concepts in a simple manner, but Davis appears to have ignored all this and given us a language tutorial. The publisher's web page for the book says "very emphatically, this is not a book about programming JavaScript." If that's so then I'd argue that it isn't a book about learning the principles of programming either.
It is obvious from this book that Davis is an excellent writer; if he had tried to write a book to teach JavaScript and had focused on the tasks for which it is often used this, volume may have been superb. As it is, he has shot for a higher goal and fallen far too short.
If you would like to check it out for yourself, you can go to the web page for the book where there is sample chapter, the Table of Contents (though they call it a "Detailed TOC" as distinct from the 'Table of Contents,' which is just a list of 11 chapter titles) and index, all in PDF format.
I went looking for a book that I could give to my 11-year-old daughter now that she has become interested in "what Daddy does." I'm still looking, I'm certain that this one isn't it.
You can purchase Learn How to Program Using Any Web Browser from bn.com. Slashdot welcomes readers' book reviews -- to see your own review here, read the book review guidelines, then visit the submission page.
Why this:
Harold Davis has started with a marvelous idea, teaching programming using a language available on all platforms, JavaScript
Why not this:
Harold Davis has started with a marvelous idea, teaching programming using a language available on all platforms, Java
Maybe because that book has already been written?
The best way to learn how to program is to sit down in front of a computer with a reference handy and dive in!
geeky shirts.. funny shirts
Why Java? Everyone knows VB is the language of certified professionals.
IGN and Bioware have been using this technique to teach C++(for NWN scripting) for 3 years now
by someone who learned to code from JS :(
Having a programmer's first effort be a JavaScript pop-up with: "Hello YOUR COMPUTER IS BROADCASTING YOUR IP ADDRESS TO THE WORLD!" is just wrong
I bet this article is going to rise a lot of flames... come on.. javascript... slashdot? yeah sure...
document.write("First Post");
The last thing the world needs right now is more programmers. Teach them some other trade which won't be killed by cheap global labor.
Java isn't as bad as you say.. I use it every day.
funny shirts.. geeky shirts!
I think the reviewer's premise that 12-13 year old wants to learn programming for a specific task is bull. I think what the book is trying to speak to is how I learned to program: BASIC. I wasn't trying to DO anything specific it was just a good way to start playing around because it came free w/ the computer and you could make it beep or say hi or whatever. I think that posing javascript as a replacement (now that basic does not come packaged with the OS) is a GREAT idea. It's free, there is a developing environment built right in (well with mozilla at least) and it's actually fairly powerful while still beaing easy to learn.
Learn programming in Python instead. Remarkably easy, yet powerful - in fact one of the most powerful programming languages you can find, and platform independent.
Is that even considered a browser these days? :)
Want to improve your Karma? Instead of "Post Anonymously", try the "Post Humously" option.
The web browser is *not* an IDE. You do the programming in vim/gedit/notepad. (emacs is a bit much for javascript IMO)
...PHP?
"Good, bad, I'm the guy with the gun."
none of which come standard w/ the computer or are particularly easy to set up if you know nothing. That was what was great about BASIC and is great about javascript. it's there. you don't have to install, configure, change your path, anything. all you have to do is go.
Java != JavaScript, but thanks for trying.
I know this was meant as funny, but Java is a normal accepted language. Because it is more structured then Perl or other languages, I highly reccomend Java to beginners.
Javascript, or ECMA script, is a terrible non-standardized (despite being created by a standards board) peice of junk.
I'm a good cook. I'm a fantastic eater. - Steven Brust
5/5? 5/10?
useless
I *wish* JavaScript had Java like syntax. I can't count how many times I've typed this:
//do something with item
//do something with item
for(int i=0; i<length; i++);
when I meant to type this:
for(var i=0; i<length; i++);
or even worse:
function func1()
{
for(i=0; i<length; i++) func2(i);
}
function func2(item)
{
for(i=0; i<length2; i++)
}
when I meant to type:
function func1()
{
for(var i=0; i<length; i++) func2(i);
}
function func2(item)
{
for(var i=0; i<length2; i++)
}
(For those of you who don't know JavaScript, "i" will be global without that "var" definition.)
Javascript + Nintendo DSi = DSiCade
I've done a fair bit of Javascript programming, I think it's an okay language. It certainly could be worse. But here are some random issues that I think may make it difficult for beginners to pick up:
1) No print() or echo() function. If you want to write something to the equivilent of stdout, you need to use document.write(). And if you use alert() as you're debugging something, you'll quickly get tired of boxes that pop up, I know I have.
2) Weird OOP syntax. If you want to create class foo, you first create function foo, then to create a method you go and create function foo.prototype.bar(). I think that's needlessly complicated. It also leaves the beginner open for a shock when they start studing OOP syntax of other languages, where a class is defined and its functions are actually defined INSIDE the class.
3) No file/database support. Good luck trying to interact with a file or database from Javascript. As the user learns more about programming, they're going to want to use these sorts of things. Javascript just wasn't designed for that.
Those are the biggest things off the top of my head on why I believe Javascript is not an ideal choice for beginners. (I don't claim to be a JS god, so if I'm wrong about any of the above, someone please correct me...)
it is a simple and clean way to learn about loops and variables for a beginner. It looks enough like other languages so that someone can easily move on to harder meatier stuff. I can't think of a better way to learn myself.
Is an interactive interpreted language.
You type, it answers.
A shell, if you like.
This should be possible with JavaScript, and it would be a cute thing.
And yes, it should be possible to give this to a 12 year-old and see them learn to program.
Once they understand what 'code' is, they can start to work with more complex tools.
By the way, this has already been done, it's called BASIC.
Don't you get it, Emacs is the browser and the IDE all in one! It does your laundry too!
Ironic.
bye
Like this will help anyone learn to actually program. Wow, I can make a webpage that has dancing bunnies, I'm l337! Anywho, I don't see how this could be useful to anyone, except maybe to help a Joe SixPack user learn a bit about how things work. If anyone is starting programming maybe try: normal java, python, C++, etc. and try to learn what a data structure is before learning about event driven programming.
Javascript for the Absolute Beginner is the book to get for learning programming skills, from breaking up chunks of a job to writing algorithms to pre-planning your work (state your problem, etc.).
Javascript is a great tool to learn programming, but unfortunately, most Javascript books out there fail to express that fact.
This is a crappy environment for beginners. The first thing they will bump into is crap-loads of IE vs. Mozilla vs. Netscape JavaScript inconsistencies. The second thing they will bump into is "how do I save information per user, not per browser". The answer is server code, probably in a different languages than JavaScript, so now newbies have to keep two things straight.
Python has fewer real world uses than JavaScript.
I'd have to disagree with you. The syntax is very similar to C/C++/Java - (don't flame me because its not *EXACTLY* the same - and it is more limited) - and secondly, "but it's full of exploits" - Maybe the interpretter on some platforms gives it power outside the boundries of the language but that is *NOT* the language's fault. Javascript is a tool and has its place and usefulness just like any other tool.
For teenagers learning to program?
... I'm staggered.
I'm
Maybe they should download 10 different browsers and then they can learn the joys of cross-platform programming too.
Sure glad noone suggested Javascript when I was learning to program.
not only does it's syntax suck (think java)
And you prefer what, VB? I personally prefer C style syntax, the only thing that I dislike about Javascript is that are the camelCase function names (was it getElementById, getElementByID, or GetElementById?).. somewhat annoying but not terribly so.
One of the oddities of JavaScript is string concatenation. It uses plus (+) for both concatentation and adding, and this creates confusion and kludges. For example, sometimes you have to say "foo + 0" to force it to "see" foo as a number. Other scripting languages have seperate operators for each. Plus JavaScript has a lousy set of string-handling functions, or at least the earlier versions did. Further, I don't like it's object-oriented tilt feeling that it was just chasing the OO fad stoked by Java, but I suppose this is a personal preference best left to some paradigm war in another place. At least it has user-defined functions.
Table-ized A.I.
Any suggestions for better introductory programming instruction?
What this world really needs is more web pages by 12-year-olds with funny little interactive images and little rainbow sparkly things that follow your mouse around. Thanks, Harold.
I would teach programmers a little accounting, how to do support, and not expect the only acceptable job is compiler designer or some bleeding-edge technology.
I find programmers who are flexible and have some people skills to be doing quite well in the global economy.
If the book's actual target audience is 12ish, I don't really see JS keeping the attention of children.
I also don't think most 12-14 year olds really want an in-depth discussion of programming principals, like the review suggest. I think they'd rather it be fun. That could just be me...
Though it's not free and only works on a couple of platforms, I think Flash and ActionScript are a great way to introduce people, especially young people, to programming. A few simple lines of code can replace the timeline based motion tweening and is a great, visual way to see how your code works. From there kids can add a few lines of code to make sound and images work interactively.
True, it might not turn them into kernel hackers, but most kids would probably more interested in learning to program if it kept their attention. Action script can be very easy with many neat things taking only a few lines of codes but it can grow as your young programmer learns more and seeks more challenging projects.
Otherwise, no need to be training any new programmers.
BC
- It has to be easy to learn and use. In order to build the novice's confidence, it should encourage early successes. It should be easy to debug.
- The tools have to be accessable to the student. Ideally, you want to use a language which is already installed on their computer, or at worse be a free download which will run on all major platforms.
- It has to be practical. If the student can't use it to do something which is useful TO THEM fairly early on in the learning process, they probably won't stick with it.
- It has to provide a good foundation for future learning. This means that it should support all the standard code constructs and have a syntax similar to other more advanced languages. It also means that it shouldn't teach them any bad habits they'll have to unlearn later.
I'm sure there are other qualities, but this is a pretty good starting list. On the basis of this simple list we can eliminate a lot of potential candidates as first language.Why is it that the proponents of "one nation under God" are so eager to get rid of "liberty and justice for all"?
As many other posters have commented - JS comes "free" with Windows. Just like Basic did way back in my youth with a BBC Micro.
The greatest problem I have with programming today is that it's so damn hard to install the compiler! Java is probably just about the easiest, but you still need to add PATH statments.
XAMPP makes installing PHP as simple as it could be.
The last time I tried to install ANT or GCC or anything even vaugly complicated I had to wade through a hundred different URLs to find the right package, download, install, edit INI files and PATH statement, fiddle with the registry and GAAAAAAAAAAHHHHH!!!!!
We can all agree the JS isn't the best language on the block. But unless it comes in a ready to go package - most people just won't bother.
It's the same thing as Linux ('scuse me while I rant) you spend ages and ages installing and configuring the damn thing when all you wnat to do is work!
Right. Rant over. To conclude - JS bad, installing IDEs and compiles: worse!
If a square is really a rhombus, why aren't all triangles purple?
most program headers start off with something like
if netscape
if netscape3
else
else if opera
if opera5
else
elsif explorer
elseif mac
elseif explorer 5
elseif explorer 5.5
elseif explorer 6.0
else
nothing like a consistant clean language.... and this is nothing like one.
but then java has some of the same problems in some areas
No, Visual Basic for Applications. Nothing like Excel macros to learn computer science!
sulli
RTFJ.
The reviewer makes an excellent point. Programming is a *means to an end*. People don't learn how to program just so they can say they program. To not put the art of learning programming into the context of real-world applications is counterproductive.
Then again, pardon me for being cynical, but this seems reflective of the new type of motivation we have these days behind people choosing vocations. People go to law school, not because they have any interest in law, but because they're under the impression they can make money if they're a lawyer. The bottom line is that if you get into any vocation without having any passion or interest, you'll never be any good at it.
This reminds me of the arguments over which programming language is best. It's moot. The application and environment should dictate which tools be used. Likewise, if you want to learn to program, and don't know for what platform or application you're interested, you're on the wrong track... figure that out before you buy any books.
Because everyone with a web browser has a JavaScript interpreter on his computer already.
Nothing to install, nothing to compile, nothing to configure. Those steps scare people.
All's true that is mistrusted
Most people haven't even figured out how to make a page look good in more than one browser.
See the Any Browser Campaign.
[And I don't mean 'detect what browser they're using, and serve them a page that's specially tailored to their browser', I mean making a single page that is written to the standards, and doesn't look like crap when some new unknown browser renders it]
We know JavaScript isn't good for 'Any Browser', as there are browsers that don't support it -- and it's even frowned upon by the WAI
Build it, and they will come^Hplain.
You certainly don't need an advanced programming language to start programming. I started programming using Quake-C, and continued with C/C++ and Java. Javascript is very similar to these languages syntax-wise, and is very easy to get started with.
My real complaints about this book centre on the abstract nature of the discussion
I also have a complaint about the target audience for this book
I also take issue with the title: this book doesn't really teach 'programming' much at all
Yet the book review rates a 5? What gives? I would think a book with more than one "I have issue with" would rate a bit lower than "the best possible rating it could get."
Saying Android is a family of phones is akin to saying Linux is a family of PCs.
Yes, that's just what we need - every Joe, Shmoe, and Harry that surfs the web to start thinking he's hot shit on Sunday because he's a "programmer", and now he can go out and grab one of those elite tech jobs!
Of course, knowing the stupidity of HR, they'll likely get hired.
~/ssh slashdot.org ssh: connect to host slashdot.org port 22: too many beers
Teach more people JavaScript?!? Put this on the shelf right beside Mein Kampf plz.
No seriously.
It's easy, it's pretty, you get a grasp of functions and objects and you can do moderatly complex things pretty quickly which means that they'll get instant gratification.
If you want to introduce them to programming, given them something that can make them go "wow!" pretty quickly. Thats what made those Spectrum BASIC books so good - within 10 minutes you had lots of pretty squares up on the screen.
I'm sure a lot of people would shudder at the though and want their kids to start with C++ or Perl - but I think that it might do more damage than good. No one wants to be scared off by pointers or regular expressions.
Avantslash - View Slashdot cleanly on your mobile phone.
If they have a browser, the kiddies can get the Squeak plugin (Smalltalk), go to Squeakland and have a lot more fun. They can start much younger too.
Java? Sure, but let's see that 31 MB download over Mom and Dad's dialup line. Java is just Smalltalk anyway, with syntactic sugar. -- It's a joke OK?
I keep seeing those "Fighter Maker" and "RPG Maker" PS2 games on the shelves. Seems like that would be the thing to give a 12 or 13 year old to get them interested in programming and maybe learn some of it's basics.
[Set Cain on fire and steal his lute.]
You can't program with JavaScript no matter how hard you try. The reason why is part of the name, JavaScript is a scripting language... there's a difference.
Here is a course I helped design to teach Javascript programming to CS170 students-- pre-business majors.
Javascript was our idea of a language replacement for what we were using True Basic. The idea was to have a language where the students wouldn't constantly question why they were learning it, and to pretend like we were doing some level of web enabled e-commerce site programming.
The problems we have found come from the lack of structure of the language, and combined with the browser's desire to fix as much as it can. While this is a nice feature for a real developer, it sucks when you have to tell a student "I know it works on the browser, but it's still wrong."
The other issue is trying to keep to a small set of structures for programming, and making sure the TAs for the course don't get too ambitious with teaching dozens of alternative ways to accomplish the same thing. For students at this level, they just get confused.
But it does work well, and it is nice not having to ask students to buy another piece of software to program with at home. (Unlike True Basic.)
I demand a million helicopters and a DOLLAR!
The author is not at all pleased with the work.
Do you think he considers it to be a 5/5 - a perfect score?
Of course it is 5/10.
I would certainly agree that Javascript is horrible (or at least used for horrible things), but as far as teaching basic programming concepts (especially in a restricted/limited environment), Javascript is probably quite appropriate. I just hope that people would eventually move on to a different language, such as C.
This is a book for children 12-13 according to the author. How many children who don't already know how to program read Slashdot? How many Slashdotters with children would be interested in this book when they can teach their kids themselves?
Support the First Amendment. Read at -1
I began teaching my brother programming with Javascript. I also recommended to my department head that they use Java as a beginning programming introduction.
You need to learn the fundamentals of programming - not necessarily Assembly-level, but something that, upon completion of a beginning course, will be useful and applicable to other languages.
We spent three weeks learning conditionals, loops and case - in my Java course (specifically did not use the word "class" there, for anti-pun reasons...). The prerequisite courses were "intro programming" and another, such as VB. But all but three of students came into the class unable to understand an if-else. My time was wasted, my prof was furious and most students gave up.
You know what they learn in the intro programming class? QBASIC. You know how many people had a clue coming into Java or VB or C++? Two of us. We'd both been programming for ten years (and we were 20) and could teach the class. It was a req. for the major, so we had to take it.
Programming is best learned in front of a computer, with a task to do and a good reference to rely on. If that reference is a book, another programmer or freakin' Google, you can still learn the basics from there. I liked the idea of teaching my brother using Javascript because I could 1 - look at his code, 2 - point him at countless resources, examples, etc. and 3 - demonstrate that even if your code follows the rules, works on your machine and is well commented/indented, it won't work on everyone else's machine.
It won't teach you the inner workings of a machine (previous Slashdot post on Assembly as an intro language) but it will help prepare you for a real internship or at least for a class that will teach you more.
...because I'm afraid the Secret Service might interpret that as a threat against the president.
an anonymous coward already echoed the sentiment that I have, mainly that a rating of 5 is not descriptive at all. Why not standardize a scale for all slashdot book ratings? This would help clear up confusion.
1) There is the ever-popular 0-10
2) A star rating (0-4 for movies, 0-5 for music), with a possible adjective afterwards (A must have, worthless, etc.)
3) The letter scale (F-A+)
4) Or even the Glengarry Glen Ross scale, where a book could only have 1 of 3 ratings (Cadillac, steak knives, you're fired)
Any of these would be preferable than just a number
...the browser *must* be tightly integrated with the OS! This will enhance the user experience!
Chinpokomon! You Americans have such large penis! Gargantuan penis!
Test your m4d n3rd skillz on this test.
/.-crowd can do better than that. But I warn you, the questions ARE ridiculously difficult at times... ;)
I just scored a meager 40,5% and I hope the
Instant Hacking
KFG
I haven't programmed in VB for quite a while, but I always loved the debugger. It is so well integrated and easy to use!!!
Sure Javascript can be used to teach programming, but if what you do is not at least a bit useful, it won't catch teenagers attention for long. And javascript is quite powerful, even though it lacks some functions that would make it perfect (external file reading, that could be made from the same url as .js file, for security reasons).
Or we con go back to basic, which could be handled on a disk (or CD), so learning to program would be quite easy!!!
Want to learn Manga P2P way? try www.mangaschool.com.
Newer versions of Mozilla have a complete debugging subsystem for javascript. You can step through the code and examine variables. All the fancy stuff that a debugger provides - that too wrapped in a nice GUI.
My other dog is a Wienerschnitzel.
did you read the review? I'm thinking maybe the part that goes:
Most adults and even teenagers don't want to 'learn how to program' as much as they want to learn how to use a tool to perform a task.
I don't think so...
The most rabid believers in American Exceptionalism are the exact same people whose policies are destroying it.
li $s1,1
li $s2,0x10000000
li $s3,0
move $s4,$v0
li $s5,1
li $s6,3
li $s7,2
I hate to say it but programming in a non-compiling non-typed language is just as irritating to a beginner as it is to an advanced programmer.
I never understood why typing is supposedly such a difficult concept for beginners.
love is just extroverted narcissism
i=9;
j=9;
j+=1;
i < j; (false)
parseInt(i,10) < parseInt(j,10); (true)
"Can there be a Klein bottle that is an efficient and effective beer pitcher?"
STL, python, and any descent OOP programming language should allow usage of + to show string concatination.
.) and for addition (the +). So in perl, "5"+4 returns 9, while "5".4 returns "54".
The problem you describe comes from the fact that a variable dosn't have a type, so you have to do + 0 to 'force' the type represintation into an integer.
In Python, for example, you can do "5"+"6" to get "56". Yet, you can't do "5"+6 because of a type mismatch. You have to do "5"+str(6) or int("5")+6 depending on what you want.
Perl is in a way simmilar to java script in the sense that it has one type 'scalar' that is both strings and numbers, and it does have different opperands for concatination (the
Helps weed out the slackers ;)
This is not the sig line you are looking for... -- Old Jedi Sig Line Trick
I'm a college freshman taking a course which uses a book very similar to this one- "Introduction to Interactive Programming on the Internet" by Craig Knuckles. So the idea of using Javascript to teach programming is not that fantastically original I guess. (The book we're using is not bad, by the way- fairly clear, although it does have some excessively stupid exercises.)
"42.857142857142854% nerd blood flows through my veins" according to the test. Amazing..... 42%, 42... Can you imagine that
I reject your reality
I'm getting ready to convert my kids' Windows XP systems over to Linux. I'm going to set up Netraverse so they can run the JumpStart (& etc) games, but I'd like to install SmallTalk or Logo so they can start to 'do more' with the computer.
Any recommendations for a 'kid-friendly' Smalltalk or Logo environment in Linux?
The nice thing about this approach is that everyone can use a browser even if they don't have an internet connection and they can get visual feedback (remember TURTLE?). And for some non-trival javascript check out the5k.org.
"Can there be a Klein bottle that is an efficient and effective beer pitcher?"
From a long time ago in a galaxy far far away, I had a Win 3.1 machine...ancient hardware, can't upgrade (both financially and technically improbable) but I wanted to learn how to program.
I had copes if GW-Basic, Qbasic, and Turbo Pascal and knew how to work with those. I wanted to learn Java but on the hardware and that whole Win 3.1 thing, this was impossible. All I knew was that I had a browser (IE) that could run Javascript (ECMAScript) so I ended up practicing my coding with it. HTML built the forms, the Javascript worked with the content. They were all toy programs but it was still educational to have done it.
I highly recommend "How to Think Like a Computer Scientist: Learning with Python." It's a great introduction to programming using a language that doesn't get in the way. Python is also a great language for starting procedurally and "graduating" to OO. Besides being a great book, it's available for free in LaTeX, PDF, PostScript, and HTML. Needless to say, both the language and the book are available "using any web browser." As for JavaScript, I have tried to keep it at arm's length for as long as possible.
I keep forgetting less than signs mess up Plain Old Text for some unfathomable reason. ;)
Here are the code snippets, rants were unaffected.
function print()
{
var i;
for (i=0; i < print.arguments.length; i++)
document.body.innerHTML += print.arguments[i];
}
function point(x,y)
{
this.x = x;
this.y = y;
function mPoint_toString()
{
return '(' + this.x + ',' + this.y + ')';
}
this.toString = mPoint_toString;
}
alert(new point(3,4));
Do daemons dream of electric sleep()?
Where can I download the "Any" browser?
It is sad that programming is becoming yet another wannabe art and is rather ceasing to be an art altogether.
- MN Karthik
I learned a lot of coding skills using the javascript red book. My only previous experience was html, so it was my first coding experience.
It's really a bad idea. Most Javascripting is about knowing DOM's and not computer science. I suppose it could be used that way, but it lacks teaching things like data types etc.
For a very introductory level it sounds ok. But really, a language like c, fortran, pascals, or maybe even BASIC is a better introductory language. I wish I had learned in c, or assembly.
Maybe I went overboard on the title, but it really is a very flexible scripting language. Many programmers fail to realize its full capability.
The last three games I wrote for my website, where I release some of my smaller projects into open source, are all written in javascript. If you ever wanted to see vector (polygon) graphics done in html+javascript, check it out.
Although it has many of the limitations that something like JS or JavaScript has, I personally think that PHP is a great first language. It does require an installation of the language (unlike JS), but I think that it has better syntax.
I am also far from being a pro, and much of my code really stinks in terms of readability (I am working on it), but speaking from the perspective of someone who had a really rough time with my one programming (we used C) class, I think PHP is better than Javascript for a first language.
"We don't know what we are doing, but we are doing it very carefully,..." Wherry, R.J. Personnel Psychology (1995)
I still think the best language to learn to program for kids (starting around 7) is Logo. Instant gratification, cool animation, you can make impressive patterns quickly and it teaches the basic control structures.
Then, they can graduate to StarLogo, an object-oriented version of logo which is easy to learn, but very powerful. A number of labs are using it for research simulation. Go with the turtle.
I've never a computer that *requires* BASIC. Sure, the C64 *came* with a BASIC version. I didn't prevent me from going to assembler, etc...
For a long time, I have felt we need an old-fashioned BASIC language with a solid graphics primitive and mouse/joystick API. I've always toyed with the notion of writing a book that taught programming through examples involving mathematical and scientific programming. Maybe I'd even throw in a little logic (basic syllogisms and computability theory [just a Turing machine]). I'd be aimed at kids. No, I won't water it down. Smart kids will enjoy it, and dumb kids can go back to playing their playstation.
I first encountered programming on a TRS-80 in BASIC. It was simple. I like the simplicity of C or Java. However, C can get a little ugly for a beginner, and Java is a tad too complex (but not a bad overall choice). I definitely don't want to touch VB. That's like teaching recursion and logic programming in -- VB. VB is a great RAD tool. However, it teaches sloppy programming habits, makes building applications a little too easy (which is great when you know what you're doing, but is bad for someone whose sole purpose is to learn). Plus who wants to learn about pseudo-random number generation or the method of least squares in VB. Oh, and I'd prefer this language be available on Linux and Windows (kids in foreign countries often use Linux [i.e. Brazil and India]).
Does anyone have any suggestions for a good BASIC interpreter or another language I could use? I could work on enhancing a simple interpreter/compiler myself.
What do you mean my sig is repetitive? What do you mean my sig is repetitive? What do you mean....
At my university, parts of the Intro to CS class was taught using JS. Already knowing the basics of programming coming into the class, none of it posed a challenge to me, but I felt sorry for the students who knew no programming. Most of them had a hard time with functions and knowing how to pass variables to them or get them to return a variable. Our final project for the class was to write a very basic "virual pest" (think tamogachi) in JS. Most had a hard time with this. A term later, we have started learning C++. I don't like using JS to write "programs" because it is very poor at reporting error messages. I think a much better choice for a first language would have been php, as, like the reviewer felt, JS has very little real world "programming" applications, but PHP could be insanely useful in real life, plus it's not overly difficult to learn and it follows much of the syntax of C/C++.
SIGFAULT
I can only assume this book begins by instructing readers to open Notepad and IE. Was there any discussion about the history of js (ECMA), how browsers differ in their implementations of js, and how ECMA compliant they are? If not, then the author is cementing IE's stranglehold on the web by teaching his readers wrong (non-standard) methods.
Does he mention other standards-compliant browsers and the development tools available with them? If this author is not at least teaching DOM techniques, the book is worthless.
A "teaching language" should be constructed a bit more carefully than the way in which VB has grown over the years.
Lasers Controlled Games!
I hate those for-loops and its entirely possible to add an .each()-iterator to all Arrays in the language. See this file for that and more.
If your tool is JavaScript, then it's almost certain your task is related to building web pages,
Or controlling Acrobat. See this PDF for the object spec.
One man's -1 Flamebait is another man's +5 Funny.
Get them started on Haskell!
To quote themselves, "Haskell is a general purpose, purely functional programming language".
The focus on the high-level "what" rather than the low-level "how" is the distinguishing characteristic of functional programming languages.
Of course, this sortof harks back to the recent debate on how all programmers should know assembly language. Guess what, they don't.
Some of these things, like cute tricks and security implications are only going to be found via trial and error. How else do you propose someone learns? Not even a training course will solve these things.. You may catch a tip or two from the instructor but in general they only teach the basics.
I'm a DBA but have done programming in the past. I may not know DB2 but I could ramp up on it rather fast because I know the basic's behind database technology which are common across any product. The same can be said for programming..
"Thanks to the remote control I have the attention span of a gerbil."
Sure, it's not packed with fancy crap, but it is simple and easy to learn and no Microsoft Tax!
http://smallbasic.sourceforge.net/
I got started with C++ (ok I had done some hello world kind of stuff in gwbasic, qbasic, pascal and such), and armed with my current level of hindsight I have to say I disagree.
My reason is that C++ is a very complicated language. There are a zillion completely non-obvious and subtle ways in which C++ manages to bite your ass.
Now for the question about which language is the best to get started in, I guess it depends on what you value as important to teach first. If you think it's important that people get some understanding in how computers actually work, know how to implement e.g. linked lists then C might be a good choice. OTOH, if you feel it's more important that they learn more high-level concepts like OO then a language like Python would probably be better.
A few years ago when I did my Masters in CS, we had to take a bunch of courses in Advanced Algorithms - math oriented stuff like Primality Testing, Numerical Methods for equation solving, interpolation, range-kutta, pseudorandomness & the like. Java wasn't widely available at that time, but all the browsers supported Javascript quite well. The Professor was a math guy, a computer neophyte who preferred that we turn in solutions ( pseudocode) using pen & paper. He didn't care too much about programming them in a real language. I wrote all my assignments in Javascript - he got his pseudocode, and he could click "Execute" & actually run it in a browser. He was quite impressed & I got an A on that. My own beef with JS is, big-number support isn' t robust. I tried testing primality for 12 digit numbers & the browser would just freeze up. However, JS actually holds up well for number crunching in the 8-10 digit range.
I'll admit the first programming language I started learning was JavaScript because I already had an interpreter for it (the browser) and I already knew some HTML. JavaScript was too limited to do the things I wanted to do, so I eventually found a decent C and C++ tutorial, purchased Visual C++ 6.0, and began learning a real programming language.
Now I'm a college freshman dealing with Java, which is nice in that I don't have to do memory management but a little on the slow side.
On vit, on code et puis on meurt.
I can't believe nobody has mentioned PASCAL! It's slightly complex, but that was the language taught in my very first programming course in college. I thought it was a nice one to start with.
:-)?
It's strongly typed, it has decent OO semantics, has freely available compilers, what's not to like
Who am I to blow against the wind? -- Paul Simon
I would certainly say that it is a good language for more experienced programmers - it is SO painless to manipulate a GUI and yet elements are easily linked to complex code. Unfortunately you can write bad VB code really easily - that is perhaps the main disadvantage. (Not having Option Explicit turned on by default is a perfect example). It's also effortless to access Windows APIs, other types of GUI widgets via OCXs, and basically there's a great "lego brick"-ness to it all. You do need to understand what's happening though to have a good program. VB is simply a tool to make things you know how to do easier - not a complete substitution.
I don't see why Java can't have as nice an IDE as VB6 though - I haven't been impressed with any I've tried. Borland JBuilder, IBM Visualage for Java, Netbeans.
None of the above had the simple indexing methods which VB6 has (copy and paste an object (e.g. button) to get option to create a control array). With the Java IDEs I've had to code arrays of buttons etc. outside the graphical interface, which rather defeats the purpose.
-- *~()____) This message will self-destruct in 5 seconds...
that it is free and the license built into the browser allows for development work. There aren't an awful lot of other programming languages/development that can boast this.
Having Javascript already available in the browsers is an advantage because a very great majority of computer tech teachers that I have met have troubles with even understanding the concept of directories and paths, let alone have a snowball's chance in hell of installing something like gcc under Cygwin.
Going off on a personal rant, I would like to see teachers be a lot more scrupulous with respect to licensing software. How seriously is a kid going to take the classroom instruction on not sharing other people's IP when the teacher tells them to download VB, QBASIC or some other clearly copywritten tool into their PCs?
As an added bonus, Javascript is not terrible to program in and you can come up with some good simple client side games. How about Pong, Tic-Tac-Toe, Minefield, Battleship, etc.?
I think that using Javascript for teaching programming is a step in the right direction, but it sounds like this book could have done a better job in making it compelling for kids.
myke
Mimetics Inc. Twitter
Georgia Tech Swiki -- for high school/college age, after the target age 12-13 under discussion.
Why not choose PHP. It's a very nice language with clear syntax, no need for a compiler, can even be run on Windows, is perfect for the web, and also for scripting. It also has enough in common with C/perl to make it easier to learn these languages (whereas say VBscript is completely foreign). It also has an easy learning curve - it's looseley typed, and gives helpful error messages.
I can recommend the book: SAMS "Teach yourself PHP in 24 hours"
Richard
Much work has been done on delivering some sort of programming environment via a browser for early CS teaching purposes - one of the students in my honours year develped a system called JavanOwl which allowed users to type simple Java programs into a textbox, and used Aspect Oriented Programming to produce an animated GIF showing the program's runtime state over time.
Pretend that something especially witty is here. Thanks.
I bet this guy must have learned everything he knows from one of those books. I know who I'm not hiring for my next web design project...
bytesmythe
Hypocrisy is the resin that holds the plywood of society together.
-- Scott Meyer
You mean like lynx? :P
:)
lynx is a superb text browser which is incredibly useful in a lot situations where I don't have access to a regular browser, and I need to use the web. Like when the boss is around, and he's only familiar with those silly GUI browsers. Heh, it sure looks like I'm doing something useful right now!
Personally, I dispise javascript, and always leave it turned off. I also only give my business to those sites which understand that no, not everyone runs javascript. At some places I've worked, they actually block JS stuff.
The reviewer is right. For most people most of the time you need a reason to learn. Necessity is the mother of all invention, remember? In general people like to see instant useable results. I think you have two groups, and therefore, two basic streams that should be followed. The first is the amateur/hobbyist and the second the professionals (people that develop software for a living). The former probably need just a language that is simple to do moderately complicated tasks, something like VB 5/6 for example. The latter need considerably more, OOP, UML, etc. Therefore the requirements for a intro language are radically different. If you are somewhere inbetween learn Python...
As someone who learned BASIC on a Commodore PET, (and later on the PC and C-64), PASCAL on a Macintosh, Visual Studio on Windows and finally Javascript -- I have to say, Javascript makes a horrible first language to learn.
First off, its quirky -- filled with bugs, platform checks, version differences, etc.
Secondly, its primary output (document.write)occurs on a pageload which makes it a very odd language indeed. Sure, you can write realtime to layers, position elements on the screen and dynamically hide and reveal data to simulate the most basic terminal functionality, but this is an enormous pain -- and hardly the place to learn basic loops, objects, functions, sorts, etc.
Javascript will always be a very strange marriage between straightforward programming, and the very weird and non-straightforward world of browsers and markup.
This is a horrible place to start.
------ The best brain training is now totally free : )
"Javascript" is what we're talking about here... not "java".
------ The best brain training is now totally free : )
lynx.browser.org. I recommend it's nice JS implementation by the way.
and i say: php if javascript is called a language, than php is much more portable, can be compiled (through zend), works on command-line also. php in 'net aware: files and urls are almost the same thing. php has the best of all the best command-line tools. in a few rows you can send and read email, convert between julian and frech revolution calendar. it does easy semaphores and multiple number precision math. it uses many sql servers as xml or db4 files. it handles ncurses, html and images as input and output. php is the macro of macros. easy and fast.
I personally prefer explicitly different operators for concatenation and addition. There have been huge language wars over this issue, but it seems a personal preference in the end.
Table-ized A.I.
Well, I suppose if you're using lynx for all your web browsing needs, chances are, you know how to program already.
T Money
World Domination with a plastic spoon since 1984
> 1. It has to be easy to learn and use. In order to build the novice's
...
:)
> confidence, it should encourage early successes. It should be easy
> to debug.
I'd say JS hits that. You can quickly write a webpage that does something ie. Displays a Fibonacci series, manipulates dates/times with very little code and what's more they pick up some html at the same time!
For debugging you've got the console/debugger in Moz/Firebird.
> 2. The tools have to be accessable to the student.
Yep. A browser with a JS interpreter is available on pretty much any platform.
> 3. It has to be practical. If the student can't use it to do
> something which is useful TO THEM fairly early on in the
> learning process, they probably won't stick with it.
I don't think it has to do anything useful per se, it has to look like it's doing something useful. Ever written something fairly complicated in C and it just prints something to a terminal? But a rollover in JS is pretty trivial and how cool does that look!
> 4. It has to provide a good foundation for future learning...
I'm not sure if JS does with it's loose typing but I reckon for just getting kids interested in programming it probably hits the spot. It's certainly a good way for them to find out if programming interests them and all they have to do is sit down at any PC with a browser on it, no mucking around having to set up the programming environment except for supplying a decent editor (no, not Notepad).
My opinion is that JS should be primarily taught at schools instead of the kids stuffing around with Word and suchlike. Ever seen how bored the kids are in class when they have to type a letter in Word? That's not computing, it's stuffing around and they're learning nothing.
Adults could start with something a bit more featureful (regards doing something that's actually useful), maybe Python.
The Machine stops.
The most you can do is help a student develop their skill. Skill is something that comes from the way your brain is wired. If you don't have it, no amount of learning will give it to you.
There are a lot of people with advanced degrees and little skill.
Bruce
Bruce Perens.
2.8.5rel.1.
Anyone who actually suggests that learning programming should be made more difficult to prevent irresponsible use has got to take the cake for elitest bullshit.
My main issue with client-side scripting is not necessarily the language/platform, but the manner in which it is used...
IMHO, it's OK for web pages to use JS or some other client-side to supplement or enhance the user experience (i.e., basic form validation, help pop-ups, etc). However, I've also seen web pages that depend on JS and I've seen that result in menus that do not work across all browsers and are often even lacking some kind of navigational alternative when the JS doesn't work.
So I agree with those who say it's not always about programming languages. It's more about universal design principles and good separation (non-interdepedence) of functional roles between client and server-side scripting logic.
I hope they don't tweak it to work only on IE.
...I really can't find this "Any" Web browser anywhere!
---- MISSING MISCELLANEOUS DATA SEGMENT --- [sigdash] trolololol
I think the Processing tool/language/environment developed by Casey Reas and Ben Fry at MIT is a great place for young people to learn. Its based on Java syntax, but has a very fast and powerful graphics API that lends itself to quickly creating visual sketches in code. Its completely free, has its own environment and compiler that is simple and easy to get started with. The website has plenty of clearly commented examples teaching concepts step by step, a nice reference page with many illustrations of the core functions and control structures of Processing, and a very helpful message board community. Most people creating in Processing share their source code, so if you see something cool you wanna try out yourself (and there is a lot of really cool work featured on the site), its just a matter of reading through the code.
So if you are a more visually inclined novice programmer like myself, in my experience, playing around in Processing can be immensely insightful and rewarding. And a lot of fun.
Women especially make me nervous.
Damn right they do. Can you hear them thinking, too? It's natural.
sig under development
JavaScript is fine but restrictive in the types of things you can do with it. QuickBASIC on the other hand, is incredibly easy and allows virtually any type of game to be made. You can learn how to do sprite animation, binary file loading and saving, scrolling, double buffering, etc. And it's free.
I learned how to program by using the sample code from 3-2-1 Contact and then modifying it to see what happened.
After 8 years of pretty much mastering QB I made the leap to DirectX and C++ without flinching. I actually learned the two at the same time. The problem is that books like the above focus too much on syntax. Syntax is not important. It is not necessary to learn 'C' style syntax to learn how to code. What is necessary is *concepts.* I still use all the concepts learned in QB in my current projects.
The main problem with books like this is that they're boring. I learned how to program by inventing a game that would require learning certain *concepts* and then learning them. JavaScript is not good for making entertaining projects. And so kids will just get bored.
QB allows you do to anything. Text based adventures, text based scrolling games, card games, graphical games. And if they want to do applications they can do that as well.
So what if you can load a JPG if you can't do anything with it. I entered in 10000 lines of data by hand in a custom graphics format of my own design to be able to have graphics I drew be loaded into my first major game. I even figured out how to "digitize" hand drawn graphics by drawing pictures on graph paper and then filling in the boxes the lines passed through. I used dirty rectangles to animate a massive character for the ending sequence.
Those skills are basic skills needed for any project. You need to be able to design file formats. Whether it's for graphics or data. And you need to be able to be creative to solve problems.
Ben
Work Safe Porn
Doh.. that's what I meant.
I say PHP is better. It is similar in style to C and Perl. It doesn't require much to set up. You can do it at home or even get some free hosting space such as geocities or something newer. They all make the use of PHP readily available and tips, tricks, and tutorials for learning PHP are all over the place. Best of all, with a little resourcefullness, you can do this all for FREE. You could even learn MySQL for the backend for nothing as well. Hell thats how I got started. Open source is great for learning.
Yet another reason why the open source communit needs to make SMIL a top-priority: Flash-style projects with the tall drink of water that is ECMAscript instead of the tub of excrement that is ActionScript.
That example works fine for me. Are you sure that you're not *really* dealing with Strings? (Use obj.toSource() to find out whether it is a String or Number.)
I've heard good things about this book,
Python Programming for the Absolute Beginner
which may be what you're looking for for your daughter. For an older teen, this book on PyGame may be appropriate:
Game Programming With Python
Yes, Python and a host of other languages can be downloaded for no cost, BUT none of them are provided ready-installed along with the OS on 99.8% of all new desktop/laptop computers today, and with 90%+ of desktop/laptop computers sold over the last 5 years.
With this book and a computer running Win98 or later (can't remember if IE on 95 has JS), or OS X (dunno about earlier versions), the user has all they need to start writing code of their own. No downloads required - hell, they don;t even have to be on-line!
Never mind the 12-13 age group - I'll be giving this to a few 7-8 year olds for birthday and/or christmas prezzies...
This sig left unintentionally blank.
Pretty good book. Covers the C++ language, though it talks an awful lot about UML flowcharts and the like -- okay if that's your style, but for my purposes, farting about with pseudocode and flowcharts is more difficult than writing the damn code in a real language -- at least Applescript, and usually C++.
That's the problem! var is the datatype and JavaScript's first inclination is to deal with it as a string! Too bad JavaScript does not offer an int!
"Can there be a Klein bottle that is an efficient and effective beer pitcher?"
I just turned 14 and I'm learning C++ as my first language. I don't think it's overly hard, though pointers did take me a few weeks to get the hang of :/. My only gripe is that it's hard to make something that I'll actually use (and thus I sometimes lose interest), because I still don't know how to import/export/create files, and because I wanted to make a few simple games but after seeing some basic OpenGL code I know I'm not going to be doing that for a while (using the tutorials at NeHe I see that I need to write a few hundred lines of code just for a blank screen...).
Any language that uses a derivative of C style syntax is not a very good choice for beginners to learn about programming concepts.
Comment removed based on user account deletion
parent.hiddenframe.location='db.php?action=save& score=12';
where db.php saves the score, and writes out some new javascript like
onLoad='parent.bigframe.scoreSaved()'
You can see a nifty example of this at my web montage tool, here: http://www.unrendered.org/unrendered/imager/
I have to disagree.
By the late 70s PASCAL was making a direct inroad into colleges and universities for the purposes of teaching programming. FORTRAN, however, was required for engineers and the sciences.
Those "bad habits" you metion pale in comparison to "computed GOTO's" in terms of readability. Yet FORTRAN code that runs to this day still uses those.
Teaching someone to program with Javascript is actually scary to me. There are so many better languages on which to learn.
Even FORTRAN.
When I was little I copied tons of type-in programs from books or magazines into the Atari. I didn't necessarily understand everything, but doing the work gave me a basic understanding of what was going on.
:P
I think a modern book based around the type-in approach, regardless of the language, would work very well, especially if it adopted an iterative model where you slowly added bits and pieces to your programs. After each new addition there would of course be some explanation of what's going on that captured the essentials of *what the computer is doing* rather than putting everything in abstract terms and relying on the kid to trust that it'll all somehow work out. An appendix at the back could provide further detail as to how the hardware operates, and the various ways operating systems work with the hardware, without necessarily becoming tied to specific hardware.
Oh, and there would be no CD containing the programs in finished form. That only encourages you to "see it working" rather than "make it work yourself."
Maybe I should write that, when I feel up to it
It says "JavaScript", not "Java". Newsflash: they're two different languages.
Maybe try some text based games so you don't have to deal with the graphics programming? Maybe a text based RPG, or something with ASCII "graphics". Either one would be fun, and would help you practice so you can better understand the harder stuff.
Good luck!
that takes nothing away from the fact that javascript is a very good language to learn programming on. i learned how to use loops and functions in javascript way before i knew what a compiler was. i say 'YAY!' to the author for an interesting and effective thought.
I write code.
That's really, really sick. That man ought to be pummeled to death with the same number of 200 page paper back books that he manages to sell.
There's always the group of people that "dispises" something that the "masses" use and like and need. I group you into the same group as people who claim "I have not owned a TV in 20 years and I'm proud of it."
However, I do use Lynx, it's handy to have around. But I don't dispise Javascript; it's pretty useful.
- It's not the Macs I hate. It's Digg users. -
Lord help somebody that learns to program using Java. It teaches you the worst programming practices ever, including using classes for everything and never cleaning up after yourself. I think that before anybody learns to program in Java, they should learn to program in C++, or another OO language, first. I don't like Java. Python is an interesting choice as a first language, I've never had that idea before. Personally, I learned to program with QBasic when I was around 9. THis could be a disaster, but I had help from both my parents, which are programmers, and they taught me about arrays and loops and subs, all those things. And then of course you have to switch from that to a real language, like C++. QBasic also makes graphics incredibly easy, which makes it great to learn as first language, as graphics are... just so much nicer. Instant gratification. QBasic isn't really available on everything. But its a far, far better first choice than JavaScript. JavaScript is also pretty incredibly unstrucutred... I don't know. I feel unsafe when writing javascript. Python is pure brilliance =). I told my dad's friend, "Python is this new languages, OOP and scripting." He shook his head and said "when I was young we learned FORTRAN and COBOL." =P So yeah, QBasic if you're under 13, and python if you're over =P.
Sure it's free, but it's not installed.
Think about the first experience you had with programming. For most people, the barrier to entry was very, very low. I.e.: They turned on their computer, and saw a GWBASIC prompt blinking at them. They were at a friend's house who had everything set up already.
I learned Basic that way. I then learned C when my Dad's friend left it on our computer after showing it to me.
It's a factor I spent quite a bit of time thinking about when I wrote my own introduction to computer programming. I really wanted to use Java as my introductory language, but that still requires an install (and command-line interaction.)
It all goes downhill from first post
I wrote an introduction to programming (w/ Javascript as the language) and thought about the IDE problem as well. I ended up writing a "Javascript Testbed" for people to use as their "IDE."
Not the best, but my main focus was _zero_ barrier to entry.
It all goes downhill from first post
I understand why the WAI deprecates ECMAScript, but if your web host provides no server-side scripting, how else are you supposed to generate content? Such hosts include file:// (used for CD-ROM based web pages) and the many banner-supported free hosts.
You're right-on there. I wrote an introduction to programming (w/ Javascript as the language) and thought about the IDE / language problem as well. I ended up writing a "Javascript Testbed" for people to use as their "IDE." Although I would have loved to use Java as the starting language, my main prerequisite was a _zero_ barrier to entry.
It all goes downhill from first post
QBasic -> C -> C++ -> Python -> ?
Start programming at 8 with QBasic. Ask your parents who know how to program about it, have them teach you if/else, arrays, subs, etc etc.
You can fiddle around with that for a while. It also has very direct access to graphics, and you get gratification once you start using graphics mode.
Then, learn C using C for Dummies, the greatest book in the universe. Then learn some C++. Then anything you want. Python is pretty great =).
Whatever you do, don't learn Java before C or C++... it's evil.
Well, maybe this isn't the best way, but its the way I did it, and I turned out fine =).
I left on one very important candidate. Donald Knuth's MIX.
This would be a poor choice for most beginners, but I've encountered a few that would fit this nicely. It is for those who REALLY want to understand how the computer works. (You'd better accompany this with a copy of the Art of Computer Programming!)
I would never recommend one of the modern assemblers, nothing since the Motorola 68000 had the necessary elegance and simplicity. But MIX does! And you can get MIX for most modern environments.
N.B.: It's important that you choose your language to match the student. I said Python, because I think it's usually the best. But there are things to be said in favor of most languages. Even Haskell if someone comes from a strong math background.
E.g., I once taught someone to program using Fortran IV. He started out being an astrologer who wanted some specialized tables calculated, and ended up a professional programmer. (Well, before he went into management.) So I've got to count that a success. But note that he was already into intricate calculations, and Fortran was a good match to his problem. (Python would have worked just as well, though.)
I think we've pushed this "anyone can grow up to be president" thing too far.
...none of those if/else and for loops...no...real programmers use tail recursion! ;o)
All joking aside, whilst I never really enjoyed programming in Prolog I could never look at a finished program and not admire its elegance. Prolog is a beuatiful language, it's just a bitch to code in if you're not used to it.
I am NaN
Yes, people, it's not learning to program in Java, it's learning to program in JavaScript. You should know better. But anyway, that wasn't my point.
Java would probably be a better language for this sort of thing because JavaScript isn't standardised. "Learn How to Program Using Any Web Browser As Long As You Only Want It To Run On That Browser And Therefore You're Going To Write For IE".
You know that don't you? Just the way you put it makes it like you know Javascript and not enough of anything else to know the bleeding obvious that Java and Javascript have nothing else in common but a similar name. Apart from that I agree, though I'd probably go more for Python ... so easy to learn. Though the easiest language I ever learnt was Basic for the Sinclair Spectrum ... took me a couple of hours one afternoon (had never seen basic before). GW-Basic was nasty and primitive in comparison. For the record my favourite languages are (in order): C++, Java, C, Python, and others.
As for Javascript, what Javascript I have done I've found much easier using the Venkman debugger in Mozilla ... why on Earth would you do it any other way?
Bitter and proud of it.
Some people despise people who can't spell.
:-))
(What do you think the chances are that I've made a stupid misteak in this message?
Watch this Heartland Institute video
As far as I know javascript does not have any exploits since without an exposed object model to operate on it can't do anything. It is purely a scripting language and its capabilities can be no greater than the thing that is being scripted. The thing that makes lastmeasure (shudder) posible is not javascript but the browsers object model - which would be just as easily exploited in any browser based scripting language.
That's very perceptive of you Mr Stapleton and rather unexpected in a G Major
You had a Mac Plus when you were 7? You aren't old enough to get nostalgic yet! :)
:)
I remember learning BASIC on a Commodore Pet, Logo on an Apple II, and assembly on a Commodore VIC-20. Around the time you were messing around with Hypercard on the Mac, ARexx was appearing on the Amiga scene, as I recall. It sticks in my memory because ARexx was often compared to Hypercard.
I wrote a program on the VIC-20 to keep track of subscribers on my paper route. I wonder if that's still on a cassette in my mom's attic? Did I ever get rid of that VIC-20, or is it collecting dust in a dark corner of mom's attic? You'll miss your memory when it goes!
-Rich
"Learn Scheme. Download "DrScheme" and use it while you go through "How to Design Programs," a free online book for learning to program with Scheme. After that, go to half.com and buy "The Structure and Interpretation of Computer Programs" for around $10 (it'll be an old edition, but that's alright) and read through it, doing all the exercises it suggests.
If you do that, you'll not only know how to program, but you'll be a better programmer than probably 97% of the people on this board. Which doesn't say much, to be sure, but you'll find that the solid basis in programming that you've developed will allow you to learn any language you want easily. And you'll be able to program well in those languages."
Dr. Scheme
How to Design Programs (Uses Scheme to teach programming)
The Structure and Interpretation of Computer Programs (also uses Scheme to teach programming)
For those who're interested in Ruby, I've found a tutorial on that as well.
= 9J =
Better books:
JavaScript: A Beginner's Guide
JavaScript Programming for the Absolute Beginner
- Jeffrey
Confucius say, "Find worm in apple - bad. Find half a worm - worse."
First off, PDF is of course misnamed, because there are of course no decent viewers for a text-only system.
That out of the way, let's talk about this "any web browser" thing.
Javascript? Yes, you can insert all the hate about Javascript and lack of security here if you like, but I don't need to worry about. You see, my browser is immune to such problems. It's lynx.
Lynx is no longer a browser? That's what your article seems to imply. The anti-lynx FUD is a little ridiculous these days. I've been told lynx doesn't support graphics, lynx doesn't support https urls, lynx doesn't this, lynx doesn't that. It gets old, certainly. But I hadn't yet heard that someone decided lynx was no longer a web browser.
"Learn to {cough} 'program' (or at least write Javascript) using *certain* web browsers, only *if* you happen to be on a machine that supports PDF."
That one looks accurate.
javascript is general enough in simple things. of course once one gets into browser manipulation, you get into trouble. but to learn basic programming, functions, loops, it shouldn't be a problem.
I write code.
Confucius say, "Find worm in apple - bad. Find half a worm - worse."
Or anything that looks fun to mess around with. Personally I got hooked on programming because of hex editors. I started of mucking around in command.com (DOS 2.1) and changing command names and error messages to funny, oftentimes stupid puns and outright jabs and the user.
After that I started noticing certain byte sequences appearing rather regularly, and then I started to unassemble some files.
Yes I learned to code in ASM, and I was about 12-13 years old then.
The grandparent was talking about javascript.
In this world nothing is certain but death, taxes and flawed car analogies.