ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
In Perl arrays are built-in, come with language, not with a module.
If you are too forgetful, let me bring you back in time to what you said:
Quote:
Originally Posted by Sergei Steshenko
Seriously, I reject Python first and foremost for lack of lexical scoping. And for lack of arrays. And for whitespaces being used to denote code blocks - and I do indent in Perl/"C".
You said "lack of arrays" is one of the reasons you reject Python. But arrays are supported in Python, both as built in lists (1D) , and a thin wrapper module (array) around C arrays. You did not specifically mention that you reject Python because it doesn't come built in like that in Perl. And you quickly change your argument in this post. And, if people finds it easier to maintain and read, then its their business. You have no reason to sound arrogant and insult their intelligence. Not sure what I am talking about? See post #20
Thanks everybody for the responses. I get the big picture that at least for Perl and Python, there are ways to perform the same tasks that are performed in shell scripts.
Perl and Python are not the only ones. There's also Ruby.
Let me tell you one piece of advice. I am a Linux Sys Admin and I used to only shell script. Me and another guy I went in took it upon ourselves to "step our game up." Him with perl, me with python. Let me tell you what, within 1 month, both of us were making "scripts" that out performed a shell script by far. Think on, combining awk,sed and bash together with phenomenal error handling and full lists and dictionaries with direct access to shell commands and there results similar to $?. MUCH more readable code (python, not Perl), with the availability of an entire test sweet "IDLE" to test all lines of code as you develop it. You cant go wrong!!! By the way, I stomped ol' perl boy as he continually tried to find "There's more than one way to do it..."
Because of it I have received praise on the error handling and power of Python's simplicity over Perl/ksh/bash/awk/sed scripting!
BTW im not saying use python. Perl is a awesome and powerful language to replace shell scripting with. Anything "upper" language is better than old school shell scripting.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.