Welcome to Linux Knowledge Base and Tutorial
"The place where you learn linux"
International Medical Corps

 Create an AccountHome | Submit News | Your Account  

Tutorial Menu
Linux Tutorial Home
Table of Contents

· Introduction to Operating Systems
· Linux Basics
· Working with the System
· Shells and Utilities
· Editing Files
· Basic Administration
· The Operating System
· The X Windowing System
· The Computer Itself
· Networking
· System Monitoring
· Solving Problems
· Security
· Installing and Upgrading
· Linux and Windows

Man Pages
Linux Topics
Test Your Knowledge

Site Menu
Site Map
Copyright Info
Terms of Use
Privacy Info
Masthead / Impressum
Your Account

Private Messages

News Archive
Submit News
User Articles
Web Links


The Web

Who's Online
There are currently, 70 guest(s) and 0 member(s) that are online.

You are an Anonymous user. You can register for free by clicking here




       This 'cheat sheet' is a handy reference, meant for begin­
       ning Perl programmers. Not everything is mentioned, but
       194 features may already be overwhelming.

       The sheet

         \     references      $$foo[1]       aka $foo->[1]
         $@%&* dereference     $$foo{bar}     aka $foo->{bar}
         []    anon. arrayref  ${$$foo[1]}[2] aka $foo->[1]->[2]
         {}    anon. hashref   ${$$foo[1]}[2] aka $foo->[1][2]
         \()   list of refs
                                 NUMBERS vs STRINGS  LINKS
         OPERATOR PRECEDENCE     =          =        perl.plover.com
         ->                      +          .        search.cpan.org
         ++ --                   == !=      eq ne         cpan.org
         **                      < > <= >=  lt gt le ge   pm.org
         ! ~ \ u+ u-             <=>        cmp           tpj.com
         =~ !~                                            perldoc.com
         * / % x                 SYNTAX
         + - .                   for    (LIST) { }, for (a;b;c) { }
         << >>                   while  ( ) { }, until ( ) { }
         named uops              if     ( ) { } elsif ( ) { } else { }
         < > <= >= lt gt le ge   unless ( ) { } elsif ( ) { } else { }
         == != <=> eq ne cmp     for equals foreach (ALWAYS)
         | ^              REGEX METACHARS            REGEX MODIFIERS
         &&               ^     string begin         /i case insens.
         ||               $     str. end (before \n) /m line based ^$
         .. ...           +     one or more          /s . includes \n
         ?:               *     zero or more         /x ign. wh.space
         = += -= *= etc.  ?     zero or one          /g global
         , =>             {3,7} repeat in range
         list ops         ()    capture          REGEX CHARCLASSES
         not              (?:)  no capture       .  == [^\n]
         and              []    character class  \s == [\x20\f\t\r\n]
         or xor           |     alternation      \w == [A-Za-z0-9_]
                          \b    word boundary    \d == [0-9]
                          \z    string end       \S, \W and \D negate
         use strict;        DON'T            LINKS
         use warnings;      "$foo"           perl.com
         my $var;           $$variable_name  perlmonks.org
         open() or die $!;  `$userinput`     use.perl.org
         use Modules;       /$userinput/     perl.apache.org
         stat      localtime    caller         SPECIAL VARIABLES
          0 dev    0 second     0 package      $_    default variable
          1 ino    1 minute     1 filename     $0    program name
          2 mode   2 hour       2 line         $/    input separator
          3 nlink  3 day        3 subroutine   $\    output separator
          4 uid    4 month-1    4 hasargs      $|    autoflush
          5 gid    5 year-1900  5 wantarray    $!    sys/libcall error
          6 rdev   6 weekday    6 evaltext     $@    eval error
          7 size   7 yearday    7 is_require   $$    process ID
          8 atime  8 is_dst     8 hints        $.    line number
          9 mtime               9 bitmask      @ARGV command line args


       Juerd Waalboer <juerd@cpan.org>, with the help of many
       Perl Monks.


        http://perlmonks.org/?node_id=216602      the original PM post
        http://perlmonks.org/?node_id=238031      Damian Conway's Perl 6 version
        http://juerd.nl/site.plp/perlcheat        home of the Perl Cheat Sheet

perl v5.8.1                 2003-09-02               PERLCHEAT(1)

An undefined database error occurred. SELECT distinct pages.pagepath,pages.pageid FROM pages, page2command WHERE pages.pageid = page2command.pageid AND commandid =




Security Code
Security Code
Type Security Code

Don't have an account yet? You can create one. As a registered user you have some advantages like theme manager, comments configuration and post comments with your name.

Help if you can!

Amazon Wish List

Did You Know?
You can choose larger fonts by selecting a different themes.


Tell a Friend About Us

Bookmark and Share

Web site powered by PHP-Nuke

Is this information useful? At the very least you can help by spreading the word to your favorite newsgroups, mailing lists and forums.
All logos and trademarks in this site are property of their respective owner. The comments are property of their posters. Articles are the property of their respective owners. Unless otherwise stated in the body of the article, article content (C) 1994-2013 by James Mohr. All rights reserved. The stylized page/paper, as well as the terms "The Linux Tutorial", "The Linux Server Tutorial", "The Linux Knowledge Base and Tutorial" and "The place where you learn Linux" are service marks of James Mohr. All rights reserved.
The Linux Knowledge Base and Tutorial may contain links to sites on the Internet, which are owned and operated by third parties. The Linux Tutorial is not responsible for the content of any such third-party site. By viewing/utilizing this web site, you have agreed to our disclaimer, terms of use and privacy policy. Use of automated download software ("harvesters") such as wget, httrack, etc. causes the site to quickly exceed its bandwidth limitation and are therefore expressly prohibited. For more details on this, take a look here

PHP-Nuke Copyright © 2004 by Francisco Burzi. This is free software, and you may redistribute it under the GPL. PHP-Nuke comes with absolutely no warranty, for details, see the license.
Page Generation: 0.09 Seconds