How can I get the month name from the month number?
For instance, if I have 3, I want to return march
date.tm_month()
How to get the string march?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
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.
Calendar API
From that you can see that
calendar.month_name[3]would returnMarch, and the array index of0is the empty string, so there’s no need to worry about zero-indexing either.