[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [K12OSN] Kids and programming

Chris Lehmann wrote:
I actually use PHP to teach programming these days. What's great about it is that, because it outputs as a web page, the kids can build really useful things really quickly, which makes them feel really good about it.

I've taught C, Java and PHP and I love PHP. It's a great first language.

I'm not so sure I agree... It lacks some very basic functionality that most grown-up languages have -- most notably namespacing. I don't think it's good for kids to start with thinking that you can use any builtin function from anywhere without doing any additional imports or include declarations.

Moreover, PHP was developed sporadically, so sometimes it has such bloopers as inconsistencies in function naming or parameter passing. Its OO design and implementation are pretty poor, and, from my perspective, teaching someone to do

<input name="<?= $variable ?>">

is doing great disservice to anyone who will have to read and figure out their code later on. :)

I would, however, agree with people who suggest Python. Its syntactic simplicity makes it great for teaching it to native English speakers. Importantly, it is easy to go from Python to almost any other language -- easier than the other way around (most people are put off by the use of whitespace as a sytactic construct).

Just a personal opinion, of course.

Konstantin ("Icon") Riabitsev
Duke University Physics Sysadmin

Attachment: pgp00011.pgp
Description: PGP signature

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]