fork download
  1. #include <stdio.h>
  2.  
  3. int mdays(int y, int m);
  4. int uruu(int year);
  5.  
  6. int main(void)
  7. {
  8. int y1, m1, d1, y2, m2, d2;
  9. int i, j, days;
  10.  
  11. while(scanf("%d%d%d%d%d%d",&y1,&m1,&d1,&y2,&m2,&d2)){
  12. if(y1<0 || m1<0 || d1<0 || y2<0 || m2<0 || d2<0)
  13. break;
  14. for(i=y1, days=0; i<=y2; i++)
  15. for(j = (i != y1 ? 1: m1); j <= (i != y2 ? 12 : m2); j++)
  16. days += mdays(i,j);
  17. days -= d1;
  18. days -= mdays(y2,m2) - d2;
  19. printf("%d\n",days);
  20. }
  21.  
  22. return 0;
  23. }
  24.  
  25. int mdays(int y, int m)
  26. {
  27. return 0;
  28. }
  29.  
  30. int uruu(int y)
  31. {
  32. return 0;
  33. }
Success #stdin #stdout 0.01s 1676KB
stdin
Standard input is empty
stdout
Standard output is empty