This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
notes:perl_cheat_sheet [2026/07/18 06:25] 114.119.135.37 old revision restored (2026/06/25 08:11) |
notes:perl_cheat_sheet [2026/07/24 13:03] (current) 47.79.201.51 old revision restored (2026/06/15 21:28) |
||
|---|---|---|---|
| Line 14: | Line 14: | ||
| * Parenthesis are optional unless part of syntax. | * Parenthesis are optional unless part of syntax. | ||
| * '' | * '' | ||
| - | * * die can be used to exit early $! will contain any system error message. Without \n at the end, perl will append line number to error message. | + | |
| ===== Numbers ===== | ===== Numbers ===== | ||
| Line 91: | Line 91: | ||
| * ''<>'' | * ''<>'' | ||
| chomp; | chomp; | ||
| - | print "It was $_ that I saw!\n"; | + | print LOGFILE |
| }</ | }</ | ||
| * '' | * '' | ||
| Line 103: | Line 103: | ||
| open BEDROCK, '> | open BEDROCK, '> | ||
| open LOG, '>>: | open LOG, '>>: | ||
| - | open BEDROCK, '>: | + | open my $bedrock, '>: |
| binmode STDOUT, ': | binmode STDOUT, ': | ||
| + | * '' | ||
| ===== User Subroutines ===== | ===== User Subroutines ===== | ||