Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3274390
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T19:01:56+00:00 2026-05-17T19:01:56+00:00

Does anyone know a way to convert a month, year, and day into the

  • 0

Does anyone know a way to convert a month, year, and day into the day’s name for any year? Example:

function convert(day, year, month)
...
return "Monday"
end

Thanks in advance!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T19:01:56+00:00Added an answer on May 17, 2026 at 7:01 pm

    You can use the following method:

    This method uses codes for different
    months and years to speed up the
    calculation of the day of the week.
    You might even be able to memorize the
    codes. We’ll use December 16, 2482 as
    an example.

    Take the last 2 digits of the year. In
    our example, this is 82.

    Divide by 4, and drop any remainder.
    82 / 4 = 20, remainder 2, so we think
    “20.”

    Add the day of the month. In our
    example, 20 + 16 = 36.

    Add the month’s key value, from the
    following table. Jan Feb Mar Apr May
    June July Aug Sept Oct Nov Dec 1 4 4
    0 2 5 0 3 6 1 4 6

    The month for our example is December,
    with a key value of 6. 36 + 6 = 42.

    If your date is in January or February
    of a leap year, subtract 1. We’re
    using December, so we don’t have to
    worry about this step.

    Add the century code from the
    following table. (These codes are for
    the Gregorian calendar. The rule’s
    slightly simpler for Julian dates.)
    1700s 1800s 1900s 2000s 4 2 0 6

    Our example year is 2482, and the
    2400s aren’t in the table. Luckily,
    the Gregorian calendar repeats every
    four hundred years. All we have to do
    is add or subtract 400 until we have a
    date that is in the table. 2482 – 400
    = 2082, so we look at the table for the 2000s, and get the code 6. Now we
    add this to our running total: 42 + 6
    = 48.

    Add the last two digits of the year.
    48 + 82 = 130.

    Divide by 7 and take the remainder.
    This time, 1 means Sunday, 2 means
    Monday, and so on. A remainder of 0
    means Saturday.

    How to calculate the day of the week

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Does anyone know of any way to convert a simple gif to xaml? E.G.
Does anyone know of an easy (built in) way to convert a string like
Does anyone know any simple way to retrieve the country from a given IP
Does anyone know a way to auto-generate database tables for a given class? I'm
Does anyone know a way to find out programatically which physical disk holds a
does anyone know a way to call a generic method of a base class
Does anyone know a way to open up an instance of the operating system
Does anyone know a way to open a 2nd form in a .NET application
Does anyone know of a way to declare a date constant that is compatible
Does anyone know of a way to alter a computed column without dropping the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.