Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Calculating days between two dates in C
#10
Nikkey Wrote:more like
Code:
int i;
for (i = year1; i < year2; i++)
  days_until += 365 + if_leap(i);

Unless you actually want to modify the contents of year1, that is.

Look at the original code. It modifies year1.
Reply


Messages In This Thread
Calculating days between two dates in C - by SaptaZapta - 2011-12-01, 09:07 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)