This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use warnings; | |
use strict; | |
use 5.010; | |
my @inc = (1..100); | |
for (@inc){ | |
if (($_ % 3 == 0) && ($_ % 5 == 0)){ | |
say "FizzBuzz"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use utf8; | |
use strict; | |
use Encode; | |
# Oniguruma \p{Katakana} https://github.com/kkos/oniguruma/blob/master/doc/UNICODE_PROPERTIES | |
my $str = "アイウaあエオワ12イウエオン"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use feature 'say'; | |
my @date = ('1月1日', '5/21', '10/46', '7/14', '3/6', '6月7日'); | |
foreach (@date) { | |
if ($_ =~ /^(\d+)\/(\d+)$/) { | |
if ($1 >= 1 && $1 <= 12 && $2 >= 1 && $2 <= 31) { | |
say |