-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path13-1.pl
56 lines (42 loc) · 1.1 KB
/
13-1.pl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
use strict;
use warnings;
use lib "./lib/";
{
use Oogaboogo::Locale (); # import nothing
foreach my $day (-1..7) {
print "Day $day ", Oogaboogo::Locale::number_to_day_name($day), "\n";
}
foreach my $month (-1..12) {
print "Month $month ", Oogaboogo::Locale::number_to_month_name($month), "\n";
}
print Oogaboogo::Locale::say_hello(), "\n";
}
{
use Oogaboogo::Locale; # import defaults
foreach my $day (-1..7) {
print "Day $day ", number_to_day_name($day), "\n";
}
foreach my $month (-1..12) {
print "Month $month ", number_to_month_name($month), "\n";
}
print Oogaboogo::Locale::say_hello(), "\n";
}
{
use Oogaboogo::Locale qw(number_to_day_name number_to_month_name say_hello);
foreach my $day (-1..7) {
print "Day $day ", number_to_day_name($day), "\n";
}
foreach my $month (-1..12) {
print "Month $month ", number_to_month_name($month), "\n";
}
print say_hello(), "\n";
}
# {
# eval{
# use Oogaboogo::Locale qw(say); # Wont compile
# print say("hello\n");
# }
# if ($@) {
# print "We can't import items if we use @EXPORT_OK and don't add our method to this list.\n";
# }
# }