hi guys .. i have an assignment .. and i didn`t now that i have to do it by tomorrow and now i have no time .. i will be thankful if you can help me..

"Write a program that determines the day number (1 to 336) in a year for a date that is provided as input data. As an example, January 1, 1994, is day 1. December 31, 1993, is day 365. December 31, 1996, is day 336, since 1996 is a leap year. A year is a leap year if it is divisible by four, expect that any year divisible by 100 is a leap year only if it is divisible by 400. Your program should accept the month, day and year as integers. Include a function leap that returns 1 if called with a leap year, 0 otherwise."