[C프로그래밍] C로 짠 날짜계산 프로그램
- 최초 등록일
- 2003.06.02
- 최종 저작일
- 2003.06
- 6페이지/ 한컴오피스
- 가격 1,000원
목차
없음
본문내용
#include <stdio.h>
#include <stdlib.h>
struct Date /* 구조체 Date를 선언 */
{
int day;
int month;
int year;
};
int array[] = {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31};
/* 각 달의 일수를 배열에 초기화를 해주고, 전역변수로 선언 */
void large(struct Date *, struct Date *); /* 입력된 두개의 날짜중 큰 날짜를 비교하여 출력하게 될 함수 large()선언 */
void days(struct Date *); /* days()함수 선언 */
void maxdays(struct Date *, struct Date *); /* 입력받은 두 개의 날짜 비교를 위한 날짜 입력 함수 선언 */
void totaldays(struct Date *); /* 1990년부터 입력받은 날짜까지의 일수 계산을 위한 날짜 입력 함수 선언 */
참고 자료
없음