(no title)
kemayo | 2 months ago
* Python has clean and readable syntax that a complete beginner can understand -- it's really close to the pseudocode you might use for teaching.
* Python has a good standard library, so you can do a lot before you need to work out how to install more (and, reproducibility concerns aside, `pip install` is really simple once you get there)
* Because it was easy to pick up and easy to use for teaching, it took over some niches like stats in academia / data-analysis, where the people doing the work aren't professional programmers but just need something they can hack together. Once NumPy existed, people had minimal incentive to move away.
(Insert Marge Simpson "I just think it's neat" gif here.)
fragmede|2 months ago
That's putting it lightly. Many jokes were made at Perl's expense on that topic, but
is a valid Perl program to grep for lines that are the file's name. One of the jokes was that it was a write only language and it was only half way a joke. Coming back to a pile of magic variables months later with no comments, omfg. Meanwhile, Python sometimes scarcely even needs commenting if it's a short script if the writer uses descriptive function and variable names.Perl's downfall, was that coming back to a ball of Perl mud after say 3 years and have to fix a bug, due to lack of classes and Perl 6 being delayed forever, you were in for not lot of fun. Python isn't perfect and that's why it's grown types, but Perl was seriously write only at times.
kamaal|2 months ago
Nobody should be spending a day writing Python to do work that can be done using a vim macro in like 5 mins. Or spend a year doing in Python what can be done in a week in Perl.
>> $\=$/;for(@ARGV){open F,$_;while(<F>){print if/$_/}}
There are lots Perl one-liner patterns, once you learn to write them. You are basically saving yourself writing many dozen man-hours of Python/Java coding work.
I remember telling my manager during the Perl days. A 10 year Java experience guy looks great, but thats basically a junior Perl dev with 6 months experience.
There is nothing to feel great about wasting effort and more importantly time.