!C99Shell v. 1.0 pre-release build #16!

Software: Apache/2.0.54 (Fedora). PHP/5.0.4 

uname -a: Linux mina-info.me 2.6.17-1.2142_FC4smp #1 SMP Tue Jul 11 22:57:02 EDT 2006 i686 

uid=48(apache) gid=48(apache) groups=48(apache)
context=system_u:system_r:httpd_sys_script_t
 

Safe-mode: OFF (not secure)

/usr/lib/python2.4/site-packages/mx/DateTime/   drwxr-xr-x
Free 3.73 GB of 27.03 GB (13.8%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     Feasts.py (2.75 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
""" Calculate moveable feasts that depend on the date of Easter Sunday.

    Copyright (c) 1998-2000, Marc-Andre Lemburg; mailto:mal@lemburg.com
    Copyright (c) 2000-2001, eGenix.com Software GmbH; mailto:info@egenix.com
    See the documentation for further information on copyrights,
    or contact the author. All Rights Reserved.
"""

import DateTime

_eastereggs = {}

def EasterSunday(year):

    """EasterSunday(year)

    Return a DateTime instance pointing to Easter Sunday of the given
    year. Note: it must be given *with* century.
    
    Based on the algorithm presented in the Calendar FAQ by Claus
    Tondering (http://www.pip.dknet.dk/~pip10160/calendar.html), which
    in return is based on the algorithm of Oudin (1940) as quoted in
    "Explanatory Supplement to the Astronomical Almanac", P. Kenneth
    Seidelmann, editor."""

    if _eastereggs.has_key(year):
        return _eastereggs[year]
    G = year % 19
    C = year/100
    H = (C - C/4 - (8*C+13)/25 + 19*G + 15) % 30
    I = H - (H/28)*(1 - (H/28)*(29/(H + 1))*((21 - G)/11))
    J = (year + year/4 + I + 2 - C + C/4) % 7
    L = I - J
    month = 3 + (L + 40)/44
    day = L + 28 - 31*(month/4)
    _eastereggs[year] = d = DateTime.DateTime(year,month,day)
    return d

Ostersonntag = EasterSunday
DimanchePaques = EasterSunday

# Some common feasts derived from Easter Sunday

def CarnivalMonday(year):

    return EasterSunday(year) - 48

Rosenmontag = CarnivalMonday

def MardiGras(year):

    return EasterSunday(year) - 47

def AshWednesday(year):

    return EasterSunday(year) - 46

Aschermittwoch = AshWednesday
MercrediCendres = AshWednesday

def PalmSunday(year):

    return EasterSunday(year) - 7

Palmsonntag = PalmSunday
DimancheRameaux = PalmSunday

def EasterFriday(year):

    return EasterSunday(year) - 2

GoodFriday = EasterFriday
Karfreitag = EasterFriday
VendrediSaint = EasterFriday

def EasterMonday(year):

    return EasterSunday(year) + 1

Ostermontag = EasterMonday
LundiPaques = EasterMonday

def Ascension(year):

    return EasterSunday(year) + 39

Himmelfahrt = Ascension

def Pentecost(year):

    return EasterSunday(year) + 49

WhitSunday = Pentecost
Pfingstsonntag = WhitSunday
DimanchePentecote = WhitSunday

def WhitMonday(year):

    return EasterSunday(year) + 50

Pfingstmontag = WhitMonday
LundiPentecote = WhitMonday

def TrinitySunday(year):

    return EasterSunday(year) + 56

def CorpusChristi(year):

    return EasterSunday(year) + 60

Fronleichnam = CorpusChristi
FeteDieu = CorpusChristi

def _test():

    import ISO,ARPA
    year = DateTime.now().year
    print 'Easter Sunday for the next few years'
    for i in range(10):
        easter = EasterSunday(year+i)
        print 'ISO:',ISO.str(easter),'  ARPA:', ARPA.str(easter)

if __name__ == '__main__':
    _test()

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 1.0 pre-release build #16 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0034 ]--