<pre id="vvttv"><mark id="vvttv"><progress id="vvttv"></progress></mark></pre>
    <pre id="vvttv"></pre>

      <p id="vvttv"></p>

          <p id="vvttv"></p>

                <p id="vvttv"></p>

                <pre id="vvttv"><cite id="vvttv"><progress id="vvttv"></progress></cite></pre>

                  <output id="vvttv"><dfn id="vvttv"><th id="vvttv"></th></dfn></output>

                    <p id="vvttv"></p>


                    ???? ??????(δ????)

                    ?????????????
                      1?????????????
                      2?????????????
                      3????????????
                      4?????????????
                    ???????????
                    ????????????????
                    ??????????????
                    ?塢??????б????
                    ???????????麯??

                    ?????????????

                    1?????????????

                    ?????? eval
                    ?????? eval(string)
                    ??? ??string????Perl?????С?
                    ?????к???????$@??????????д???$@????????????
                    ???? $print = "print (\"hello,world\\n\");";
                    eval ($print);
                    ?????? hello, world

                    ?????? system
                    ?????? system(list)
                    ??? list?е???????????????????????????
                    system?????????????г?????????????????????????????????λ??????????
                    ???? @proglist = ("echo", "hello,world!");
                    system(@proglist);
                    ?????? hello, world!

                    ?????? fork
                    ?????? procid = fork();
                    ??? ?????????????????--????????????--?????С???????????????????????????????????????ID???
                    ???? $retval = fork();
                    if ($retval == 0) {
                      # this is the child process
                      exit; # this terminates the child process
                    } else {
                      # this is the parent process
                    }
                    ?????? ??

                    ?????? pipe
                    ?????? pipe (infile, outfile);
                    ??? ??fork????????????????????????????????outfile???????????????????infile???????????????裺
                    1??????pipe
                    2????fork???????????????????
                    3???????????infile??????????outfile
                    ???? pipe (INPUT, OUTPUT);
                    $retval = fork();
                    if ($retval != 0) {
                      # this is the parent process
                      close (INPUT);
                      print ("Enter a line of input:\n");
                      $line = <STDIN>;
                      print OUTPUT ($line);
                    } else {
                      # this is the child process
                      close (OUTPUT);
                      $line = <INPUT>;
                      print ($line);
                      exit (0);
                    }
                    ?????? $
                    program
                    Enter a line of input:
                    Here is a test line
                    Here is a test line
                    $

                    ?????? exec
                    ?????? exec (list);
                    ??? ??system???????????????????????????????????fork???????fork???????????????????exec????????????
                    ????  
                    ??????  

                    ?????? syscall
                    ?????? syscall (list);
                    ??? ????????????list???????????????????????????????
                    ?????????????????????C????????(type int)?????????????????????UNIX???????Perl?????
                    ???syscall??????????syscall.pl??????
                    require ("syscall.ph");
                    ????  
                    ??????  

                    2?????????????

                    ?????? die
                    ?????? die (message);
                    ??? ?????????STDERR????????????message?????????????б????????????????????????з????????????????к?????????
                    ???? die ("Cannot open input file");
                    ?????? Cannot open input file at myprog line 6.

                    ?????? warn
                    ?????? warn (message);
                    ??? ??die???????????????????
                    ???? warn("Danger! Danger!\n");
                    ?????? Danger! Danger!

                    ?????? exit
                    ?????? exit (retcode);
                    ??? ?????????????????
                    ???? exit(2);
                    ?????? ??

                    ?????? kill
                    ?????? kill (signal, proclist);
                    ??? ???????????????
                    signal??????????????9????????
                    proclist?????ID?б?????kill??UNIX??????
                    ????  
                    ??????  

                    3????????????

                    ?????? sleep
                    ?????? sleep (time);
                    ??? ???????????????time???????????????????????????????
                    ???? sleep (5);
                    ?????? ??

                    ?????? wait
                    ?????? procid = wait();
                    ??? ?????????У??????????????
                    ??????????????????????ID??????????????????-1??
                    ????  
                    ??????  

                    ?????? waitpid
                    ?????? waitpid (procid, waitflag);
                    ??? ?????????У???????????????????procid?????????ID
                    ???? $procid = fork();
                    if ($procid == 0) {
                      # this is the child process
                      print ("this line is printed first\n");
                      exit(0);
                    } else {
                      # this is the parent process
                      waitpid ($procid, 0);
                      print ("this line is printed last\n");
                    }
                    ?????? $ program
                    this line is printed first
                    this line is printed last
                    $

                    4?????????????

                    ?????? caller
                    ?????? subinfo = caller();
                    ??? ??????????????????к??????Perl Debugger??
                    ?????????????б??
                    1????????????
                    2?????????????
                    3??????????к?
                    ????  
                    ??????  

                    ?????? chroot
                    ?????? chroot (dir);
                    ??? ???????????????chroot??????
                    ????  
                    ??????  

                    ?????? local
                    ?????? local($variable);
                    ??? ??????(????????Χ????伯??)?ж??????????????????????????????????????????????????????
                    ???????????????????????????????????μ?????????
                    ????  
                    ??????  

                    ?????? times
                    ?????? timelist = times
                    ??? ????ó???????????????????????
                    ??????????????????б??
                    1????????????????
                    2???????????????
                    3?????????????????
                    4????????????????
                    ????  
                    ??????  

                    ???????????

                    ?????? sin
                    ?????? retval = sin (value);
                    ??? ????????????

                    ?????? cos
                    ?????? retval = cos (value);
                    ??? ????????????

                    ?????? atan2
                    ?????? retval = atan2 (value1, value2);
                    ??? ????????value1????value2?????arctan?????λ????????Χ??-PI~PI??
                    ???????
                    ????????????????
                    sub degrees_to_radians {
                      local ($degrees) = @_;
                      local ($radians);11:
                      $radians = atan2(1,1) * $degrees / 45;
                    }

                    ?????? sqrt
                    ?????? retval = sqrt (value);
                    ??? ???????????value????????

                    ?????? exp
                    ?????? retval = exp (value);
                    ??? ????e??value?η???

                    ?????? log
                    ?????? retval = log (value);
                    ??? ??e?????????????

                    ?????? abs
                    ?????? retval = abs (value);
                    ??? ???????????(Perl 4?????)

                    ?????? rand
                    ?????? retval = rand (num);
                    ??? ???????????????0??????num???????????????

                    ?????? srand
                    ?????? srand (value);
                    ??? ???????????????????????ε???rand?????????

                    ????????????????

                    ?????? index
                    ?????? position = index (string, substring, position);
                    ??? ???????substring???????string?е?λ????????????????-1??????position???????????????????????????????????λ???????

                    ?????? rindex
                    ?????? position = rindex (string, substring, position);
                    ??? ??index??????????????????

                    ?????? length
                    ?????? num = length (string);
                    ??? ?????????????????????????????????

                    ?????? pos
                    ?????? offset = pos(string);
                    ??? ????????????????λ?á?

                    ?????? substr
                    ?????? substr (expr, skipchars, length)
                    ??? ???????????????????????????expr?е??????????skipchars??????????????λ??skipchars???????????????????λ???0????????????length???????????????ζ?????μ?????????
                    ?????????????????????expr?????????????????????????в?????????????????滻??

                    ?????? study
                    ?????? study (scalar);
                    ??? ??????????????????????????????????????????????á?

                    ?????? lc
                    uc
                    ?????? retval = lc(string);
                    retval = uc(string);
                    ??? ???????????????С/??д?????

                    ?????? lcfirst
                    ucfirst
                    ?????? retval = lcfirst(string);
                    retval = ucfirst(string);
                    ??? ???????????????С/??д??

                    ?????? quotameta
                    ?????? newstring = quotemeta(oldstring);
                    ??? ??????????????????б??(\)??
                    ??? ?? $string = quotemeta($string);
                    ??Ч???$string =~ s/(\W)/\\$1/g;
                    ???????????????У?????????????????????????????????

                    ?????? join
                    ?????? join (joinstr, list);
                    ??? ????????б?(????)??????????????????????????б????????joinstr??

                    ?????? sprintf
                    ?????? sprintf (string, fields);
                    ??? ??printf?????????????????????????????????????????????
                    ???? $num = 26;
                    $outstr = sprintf("%d = %x hexadecimal or %o octal\n",$num, $num, $num);
                    print ($outstr);
                    ?????? 26 = 1a hexadecimal or 32 octal

                    ??????????????

                    ?????? chop
                    ?????? $lastchar = chop (var);
                    ??? var????????????飬??var????????????????????????????$lastchar????var?????/?б???????????????????????????????????????????????????$lastchar??

                    ?????? chomp
                    ?????? result = chomp(var);
                    ??? ????????????????б????????????????????????????$/??????з???????????????????????????????????????

                    ?????? crypt
                    ?????? result = crypt (original, salt);
                    ??? ??DES?????????????original????????????????salt????????????????????????θ??DES?????????????????????????????

                    ?????? hex
                    ?????? decnum = hex (hexnum);
                    ??? ???????????(????????)?????????????

                    ?????? int
                    ?????? intnum = int (floatnum);
                    ??? ???????????С??????????????????

                    ?????? oct
                    ?????? decnum = oct (octnum);
                    ??? ?????????(????????)???????????("0x.."???)?????????????

                    ?????? ord
                    ?????? asciival = ord (char);
                    ??? ????????????ASCII?????PASCAL??????????????

                    ?????? chr
                    ?????? $char = chr (asciival);
                    ??? ????ASCII?????????????PASCAL??????????????

                    ?????? pack
                    ?????? formatstr = pack(packformat, list);
                    ??? ??????б?????????????????????????C????????????????????????????????????С?????packformat????????????????????б????????????????????????????????tab????????pack??????
                      ??????a??A??@???????????????ο???????????????磺
                       $twoints = pack ("i2", 103, 241);
                      ???????????????е????????*????磺
                       $manyints = pack ("i*", 14, 26, 11, 83);
                      ????a??A???????????????????????????????????????????£?
                       $strings = pack ("a6" x 2, "test1", "test2");
                      ???@???????????????????????????????????????????????????????????????????(null)?????磺
                       $output = pack ("a @6 a", "test", "test2");
                      pack??????????????????????C?????????????????C???????????????????(null)??β???????????????????????????
                       $Cstring = pack ("ax", $mystring);
                      ?±????Щ????????C?????????????????
                    ???   ???C????????
                    C char
                    d double
                    f float
                    i int
                    I unsigned int (or unsigned)
                    l long
                    L unsigned long
                    s short
                    S unsigned short
                      ??????????????±??

                    ??????   ????
                    a ??????(null)??????????
                    A ????????????
                    b λ??????λ???
                    B λ??????λ???
                    c ??????????????-128~127??
                    C ?????????????8λ??
                    d ??????????
                    f ???????????
                    h ???????????????λ???
                    H ???????????????λ???
                    i ??????????
                    I ?????????
                    l ???????????
                    L ??????????
                    n ???????????
                    N ??????????
                    p ????????
                    s ???????????
                    S ??????????
                    u ?????uuencode???
                    v VAX???????
                    V VAX??????
                    x ????????
                    X ??????????
                    @ ??????(null)???

                    ?????? unpack
                    ?????? @list = unpack (packformat, formatstr);
                    ??? unpack??pack??????????????????????????????Perl??????б???????????pack???????????????????????У?A?????????????????????Perl??????????β?????п?????????x????????????@??????Щ?????????λ?????@4?????4?????????濴???@??X??????????    $longrightint = unpack ("@* X4 L", $packstring);
                      ????佫??????????????????????????????????濴?????uuencode?????????????
                    1 : #!/usr/local/bin/perl
                    2 :
                    3 : open (CODEDFILE, "/u/janedoe/codefile") ||
                    4 : die ("Can't open input file");
                    5 : open (OUTFILE, ">outfile") ||
                    6 : die ("Can't open output file");
                    7 : while ($line = <CODEDFILE>) {
                    8 : $decoded = unpack("u", $line);
                    9 : print OUTFILE ($decoded);
                    10: }
                    11: close (OUTFILE);
                    12: close (CODEDFILE);
                      ????pack??unpack????uuencode??????????????????UNIX?е?uuencode??uudecode??????????????????????к???У????????uudecode????pack?????????????????н?????????????к????????????UNIX??uuencode????????

                    ?????? vec
                    ?????? retval = vec (vector, index, bits);
                    ??? ??????壬vec?????(vector)???????????????vector??????????(?)???????麬????????λ???????????????????????ε???÷????????????????????????????д??????index?????????±?????????????????飬0?????飬???????????????????????????????????????????????????bits???????е?λ?????????1,2,4,8,16??32??
                    ???? 1 : #!/usr/local/bin/perl
                    2 :
                    3 : $vector = pack ("B*", "11010011");
                    4 : $val1 = vec ($vector, 0, 4);
                    5 : $val2 = vec ($vector, 1, 4);
                    6 : print ("high-to-low order values: $val1 and $val2\n");
                    7 : $vector = pack ("b*", "11010011");
                    8 : $val1 = vec ($vector, 0, 4);
                    9 : $val2 = vec ($vector, 1, 4);
                    10: print ("low-to-high order values: $val1 and $val2\n");
                    ??? high-to-low order values: 3 and 13
                    low-to-high order values: 11 and 12

                    ?????? defined
                    ?????? retval = defined (expr);
                    ??? ?ж???????????????????????????????????????expr????????????????????????????
                    ???????壬?????棬????????

                    ?????? undef
                    ?????? retval = undef (expr);
                    ??? ?????????????????????????????????壬?????????????????δ????????????????Ч??

                    ?塢??????б????

                    ?????? grep
                    ?????? @foundlist = grep (pattern, @searchlist);
                    ??? ???????UNIX????????????grep???????б??г?????????????????????pattern???????????????????????????б??
                    ???? @list = ("This", "is", "a", "test");
                    @foundlist = grep(/^[tT]/, @list);
                    ??? @foundlist = ("This", "test");

                    ?????? splice
                    ?????? @retval = splice (@array, slipelements, length, @newlist);
                    ???   ?????????????б?????飩?м??????????????б???滻???б??????skipelements????????????????????length????滻?????????newlist?????????????б????newlist????????length???????????????????????????????????????length=0????????????б??в????????????????
                      splice (@array, -1, 0, "Hello");
                    ?????????β???????????newlist????????????????б??????????length????????skipelements?????????????????????????????????splice (@array, -1);????????£?????????????????б??

                    ?????? shift
                    ?????? element = shift (@arrayvar);
                    ??? ????????????????????????????????????????????????????@ARGV???в?????

                    ?????? unshift
                    ?????? count = unshift (@arrayver, elements);
                    ??? ??????shift??????????arrayvar???????????????????????????(?б?)???????????splice (@array, 0, 0, elements);

                    ?????? push
                    ?????? push (@arrayvar, elements);
                    ??? ???????β????????????????????slice (@array, @array, 0, elements);

                    ?????? pop
                    ?????? element = pop (@arrayvar);
                    ??? ??push???????????б??????????????????????????????б??????????δ???????(?????)??

                    ?????? split
                    ?????? @list = split (pattern, string, maxlength);
                    ??? ???????????????????б?????????pattern?????????????????pattern???????????????С?maxlength???????????????????ó????????䶮

                    ?????? sort
                    ?????? @sorted = sort (@list);
                    ??? ???????????б?????

                    ?????? reverse
                    ?????? @reversed = reverse (@list);
                    ??? ???????????б?????

                    ?????? map
                    ?????? @resultlist = map (expr, @list);
                    ??? ???????Perl5?ж??壬??????б??е??????????????expr?????????????????????????????????????????expr?У???????$_???????????
                    ???? 1??@list = (100, 200, 300);
                       @results = map ($_+1, @list);
                    2??@results = map (&mysub($_), @list);
                    ??? 1??(101, 201, 301)
                    2????

                    ?????? wantarray
                    ?????? result = wantarray();
                    ??? Perl?У??Щ???ú????????????????????????????????????????chop??????????????????????????????????????????????????б????????????????????(??)??????????(??)??
                    ???? 1 : #!/usr/local/bin/perl
                    2 :
                    3 : @array = &mysub();
                    4 : $scalar = &mysub();
                    5 :
                    6 : sub mysub {
                    7 : if (wantarray()) {
                    8 : print ("true\n");
                    9 : } else {
                    10: print ("false\n");
                    11: }
                    12: }
                    ??? $program
                    true
                    false
                    $

                    ???????????麯??

                    ?????? keys
                    ?????? @list = keys (%assoc_array);
                    ??? ?????????????????±??б??

                    ?????? values
                    ?????? @list = values (%assoc_array);
                    ??? ??????????????????б??

                    ?????? each
                    ?????? @pair = each (%assoc_array);
                    ??? ?????????????б?--?????????±???????????????????????????????????????б??

                    ?????? delete
                    ?????? element = delete (assoc_array_item);
                    ??? ????????????е??????????????????????
                    ???? %array = ("foo", 26, "bar", 17");
                    $retval = delete ($array{"foo"});
                    ??? $retval = 26;

                    ?????? exists
                    ?????? result = exists (element);
                    ??? ??Perl5?ж??壬?ж???????????????????????????????????(??)???????????(??)??
                    ???? $result = exists ($myarray{$mykey});

                    ????? ??

                    paper | appdir | ssv

                      <pre id="vvttv"><mark id="vvttv"><progress id="vvttv"></progress></mark></pre>
                      <pre id="vvttv"></pre>

                        <p id="vvttv"></p>

                            <p id="vvttv"></p>

                                  <p id="vvttv"></p>

                                  <pre id="vvttv"><cite id="vvttv"><progress id="vvttv"></progress></cite></pre>

                                    <output id="vvttv"><dfn id="vvttv"><th id="vvttv"></th></dfn></output>

                                      <p id="vvttv"></p>

                                      这里只有精品视频