Perl/Python Overview

Source: Internet
Author: User

Recently, due to project requirements,

One tool needs to be completed in multiple old Linux/UNIX versions. Some of them do not have python, so they have to regain the Perl documentation ......

Reading the Perl document is a process of vomiting blood.

Get used to the python> 2.4 syntax and core library organization, which is relatively reasonable arrangement and unified format,

Perl seems unreasonable.

I think this should be because the stone age that appeared in it caused these historical faults. The original elegance and stunning passage

The makeup of the defenders has become the virtue of the changing fairy ......

1. the keyword Syntax of Perl is changeable and strange, such as the unless loop;

2. context-sensitive usage of various functions and expressions;

 

#These two sentences are quite different ......
@ B = @;
$ B = @;

3, $ ^ $ @ $! $ | And other special variables. (The memory is poor. I haven't seen it for many years. Now I can't fully recognize these heroes)

(Of course, I heard that there is a use English; # A syntax in this format can use the pure English mode to use special variables,

But this tutorial is not even recommended ..)

4. The function parameter is omitted and not omitted; (although, this indeed improvesCodeBut it also increases the reading difficulty to a considerable extent, especially for non-

Difficulty in reading Perl code maintainers For A Long Time)

Chomp  (  $ Text     =     <  Stdin  >  );  #  For example  

Substr ( $ Str , 1 , 3 ) = " New String " ; # For example, this amazing syntax ......

5. The standard library is numerous and messy;

Compared to the poor C ++ standard library, the Perl standard library is indeed rich, but it is a headache for organizations and messy placement ..

File: basename;

File: spec; # This is the OO implementation method. The Calling format is different from that of other modules ...... Crash

CWD;

For these things, a python OS. Path is basically overwritten.

In a word, we don't like Perl, life is short, you need python.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.