// returns the day of the week from the Gregorian Date
returns the day of the week from the Gregorian Date
returns the day of the week from the Gregorian Date
pub fn zellers_congruence_algorithm(date: i32, month: i32, year: i32, as_string: bool) -> String {
    let q = date;
    let mut m = month;
    let mut y = year;
    if month < 3 {
        m = month + 12;
        y = year - 1;
    }
    let day: i32 =
        (q + (26 * (m + 1) / 10) + (y % 100) + ((y % 100) / 4) + ((y / 100) / 4) + (5 * (y / 100)))
            % 7;
    if as_string {
        number_to_day(day)
    } else {
        day.to_string()
    }
    /* Note that the day follows the following guidelines:
    0 = Saturday
    1 = Sunday
    2 = Monday
    3 = Tuesday
    4 = Wednesday
    5 = Thursday
    6 = Friday
    */
}
pub fn zellers_congruence_algorithm ( date : i32 , month : i32 , year : i32 , as_string : bool ) -> String { let q = date ; let mut m = month ; let mut y = year ; if month < 3 { m = month + 12 ; y = year - 1 ; } let day : i32 = ( q + ( 26 * ( m + 1 ) / 10 ) + ( y % 100 ) + ( ( y % 100 ) / 4 ) + ( ( y / 100 ) / 4 ) + ( 5 * ( y / 100 ) ) ) % 7 ; if as_string { number_to_day ( day ) } else { day . to_string ( ) } /* Note that the day follows the following guidelines:
    0 = Saturday
    1 = Sunday
    2 = Monday
    3 = Tuesday
    4 = Wednesday
    5 = Thursday
    6 = Friday
    */ }
returns the day of the week from the Gregorian Date
returns the day of the week from the Gregorian Date
date
i32
month
i32
year
i32
as_string
bool