Project Report (Calendar)
Project Report (Calendar)
Student Details
Name ID
[For Teachers use only: Don’t Write Anything inside this box]
1|Page
Lab Project Status
Table of Contents
Chapter 3: Conclusion 9
3.1 Learning Outcome
3.2 Future Scope
2|Page
Chapter 1
Introduction
1.1 Introduction
This report has described the successful simple development of a calendar
program. This report outlines the design and development of a computer
software system to code blocks. The program was written in C language.
Basically calendar operation done in this project application. To find out of
the day corresponding to a given year and get calendar.
It is compiled in code::Blocks using GCC compiler
1.3 Objectives .
3|Page
To display the calendar interface.
Input your favorite year and get date/month and day in week.
To build a calendar successfully gaining all the required
knowledge.
To apply our knowledge and understanding into practice.
To know about the working of each and every component and their
role.
Chapter 2
#include<stdio.h>
4|Page
int day=(year*365 + ((year-1) /4) -((year-1) /100) +
((year-1) /400)) % 7;
return day;
}
int main()
{
char *months[] ={"January", "February", "March", "April",
"May", "June", "July", "August", "September", "October",
"November", "December"};
int daysInMonth[]={31,28,31,30,31,30,31,31,30,31,30,31};
int i,j, totalDays, weekDay =0, spaceCounter= 0, year;
totalDays =daysInMonth[i];
5|Page
for(j= 1; j<= totalDays; j++){
printf("%6d", j);
weekDay++;
if(weekDay >6){
weekDay = 0;
printf("\n");
}
}
}
return 0;
}
In this program, user take the input of their favorite year. And it will be
executed and show the output of the calendar interface.
6|Page
Chapter 3
Conclusion
From this assignment, I have learnt to implement a few C concepts in the future
projects such as loops, conditional statements, increment and decrement in the
program. I have also gain some knowledge of IDE: codeblocks and also trying
other IDE for better coding in the future.
7|Page