Help for this page

Select Code to Download


  1. or download this
    shell> perl -le 'print "yep" if "foo bar" !~ /baz/'
    yep
    
  2. or download this
    shell> perl -le '$_="xfoo"; print; substr($_,0,1)=""; print'
    xfoo
    foo
    
  3. or download this
    shell> perl -le '$_="xfoo"; print; s/^.//; print'
    xfoo
    foo
    
  4. or download this
    shell> perl -le '$_="foo,bar,baz"; print; s/,[^,]+$//; print'
    foo,bar,baz
    foo,bar