They are all script languages. They are executed directly after being written without compilation.
Perl is used to process the parsing of a large number of texts.
Shell is suitable for system management, such as automatic completion of a series of
Putty
Regular ExpressionsReview:@ Array@ Argv@ Marr multi-dimensional array
Difference between Su and sudo commandsHttp://linux.chinaitlab.com/command/730542_2.html: WQ is mandatory to write files and exit. Write the file forcibly even if it is
Today, we built a web environment, Apache + Perl, and mounted CGI to test the performance. However, we suddenly encountered several problems.The command line support for starteam cannot be found for listing all the projects of the company on the
#! /Usr/bin/perl open DL, "list" | die "Open error $! "; % hash; while () { # Print $ _; my ($ A, $ B, $ C, $ d) = Split ('_', $ _); my ($ D, $ e) = Split (//. /, $ C); $ hash {$ _} = $ D; # Make a hash key and set the file name value to the
On the China Mobile Game channel, the player paradise game in the game player package is now available. As one of the developers, we have added so many classes that we can see the results and are excited. Haha, various PV and UV data statistics
According to Xiao Peng, first change the detection script of yesterday to the one with the reset function, and then send the alarm prompt to the specified mailbox by email.
Certificate ---------------------------------------------------------------
Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->
#
! /Usr/bin/perl-W
$ Line
=
Stdin
>
;
Chomp
(
$ Line
);
If
(
$ Line
= ~
/
(
^
[
-
Za
-
Vars in Perl is a pragma (precompiled indicator) in Perl that is used to predefine global variables. These predefined global variables are in the QW () list, it can be used in the entire referenced perl file. Even if you use strict, no error is
1) how to find the number of times a character appears in a string?
Source: http://www.perl.com/doc/FAQs/FAQ/oldfaq-html/Q4.24.html
If you want to find the number of occurrences of a character (x) in a string, you can use the tr // function and
Preface
According to the Perl Language Reference Manual, Perl isPractical Extraction and Report Language(Practical report extraction LanguageIt is designed by Larry Wall and constantly updated and maintained for programming in UNIX environments.
There are three methods to use shell commands in Perl:
System Functions
''
QX {}
First, the system function format is as follows:
System ("command ");
If the command runs normally, 0 is returned; otherwise, a non-zero value is
Command :#Notes: remark announcementExample: # This program is a demo Annotation
-------------------------------------------------------------------------Command: PrintSyntax 1: Print filehandle listNote: This filehandle serves as a bridge between I
Command: Print
Syntax: Print filehandle list
Note: This filehandle can be seen as a bridge between I (input) and O (output). You can use filehandle to read and write data. stdin indicates the connection from which data is input, for example, input
Posted on Netease blog 13:07:36
1st and 2nd
#! Perl-W# Chapter 4, exercise one and twoUse strict;Sub Total {My $ sum;Foreach $ _(@_){$ Sum + = $ _;}$ Sum;}My @ Fred = (1, 3, 5, 7, 9 );Print "sum of (@ Fred) is: \ t", & total (@ Fred), "\ n ";
Print "
File: whox. pl;Function: lists who is on the system. If the same user has logged on to the group multiple times;Description: lists the user logon times, virtual terminal numbers used, and corresponding IP addresses;Advantage: it is more intuitive
The inheritance of Perl classes (packages) is implemented through the @ ISA array. In short, Perl regards it as a special array of directory names, similar to the @ INC array (the @ INC array contains a reference path ). When Perl cannot find the
Document directory
My debugging Philosophy
Title
Brian's Guide to PerlOutline
Read this guide and stay informedDescribe my debugging Philosophy
I believe there are three things:
This is not a personal issue
Don't always think about your code.
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