Hebrew calendar software creators: can you notify this list when updating the calendar?

Hebrew calendar software creators: can you notify this list when updating the calendar?

Shlomi Fish shlomif at iglu.org.il
Thu Apr 15 19:39:15 IDT 2010


Hi Kobi,

On Thursday 15 Apr 2010 18:37:18 kobi zamir wrote:
> I forgot to change the line
> 
> my $h = hdatec::new_Hdate();
> to
> my $h = new hdate::Hdate();
> 

this is called indirect object notation. It is recommended to do:

	my $h = hdate::Hdate->new()

Instead. Otherwise, looks fine. Thanks for correcting the code.

Regards,

	Shlomi Fish

> On Thu, Apr 15, 2010 at 6:34 PM, kobi zamir <kobi.zamir at gmail.com> wrote:
> > Ohh.... Perl is an ugly language ...
> > 
> > Here is the perl code with shlomi's sugestions, it works just the same.
> > 
> > #------------------------------------------
> > use strict;
> > use warnings;
> > use hdate;
> > 
> > my $h = hdatec::new_Hdate();
> > 
> > $h->set_gdate(1,1,2010);
> > 
> > my $julian = $h->get_julian();
> > 
> > for(my $i = 0; $i < 365; $i++) {
> >        $h->set_jd($julian + $i);
> > 
> >        my $day = $h->get_gday();
> >        my $month = $h->get_gmonth();
> >        my $holyday = $h->get_holyday_string(1);
> > 
> >        if ($holyday) {
> >                print "$day/$month $holyday\n";
> >        }
> > }
> > #------------------------------------------

-- 
-----------------------------------------------------------------
Shlomi Fish       http://www.shlomifish.org/
Interview with Ben Collins-Sussman - http://shlom.in/sussman

Deletionists delete Wikipedia articles that they consider lame.
Chuck Norris deletes deletionists whom he considers lame.

Please reply to list if it's a mailing list post - http://shlom.in/reply .



More information about the Linux-il mailing list