How do I indicate the weekday for a specific month and year in C++?
I am building a calendar in the terminal using C++ 14, and I want to indicate the week day (Mon - Sun). Basically, the user inputs a month and a year. Example Input: October 2026 What I want is for the program to output the numbers of days associated with the day of the week. Example Output: October 2026 1 Thursday 2 Friday 3 Saturday So far, I am only able to output the days (1 - 31) and input month and year using ctime calendar, but how do I indicate the weekday? I've been looking through the Cppreference, Youtube, and https://www.tutorialspoint.com/c_standard_library/c_function_mktime.htm,
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.