//#include <bits/stdc++.h>
#include <iostream>
#define rep(i,l,n) for(int i=l;i<n;i++)
#define rer(i,l,n) for(int i=l;i<=n;i++)
#define all(a) a.begin(),a.end()
#define o(a) cout<<a<<endl
#define fi first
#define se second
using namespace std;
typedef long long ll;
//typedef vector<int> vint;
typedef pair<int,int> pii;

int y1,m1,d1,y2,m2,d2;
int md[13]={0,31,28,31,30,31,30,31,31,30,31,30,31};
int mdl[13]={0,31,29,31,30,31,30,31,31,30,31,30,31};

bool leap_year(int y){
	if(y%4==0 && y%100!=0 || y%400==0) return true;
	else return false;
}

int days(int y,int m,int d){
	int ans=0,cm=1;
	while(1){
		if(cm==m){
			ans+=d; break;
		}
		else if(leap_year(y)) ans+=mdl[cm];
		else ans+=md[cm];
		cm++;
	}
	return ans;
}

int main(){
	while(1){
		int ans=0;
		cin>>y1>>m1>>d1>>y2>>m2>>d2;
		if(y1<0||m1<0||d1<0||y2<0||m2<0||d2<0) break;
		while(1){
			if(y1==y2) break;
			else if(leap_year(y1)) ans+=366;
			else ans+=365;
			y1++;
		}
		ans+=days(y2,m2,d2)-days(y1,m1,d1);
		o(ans);
	}
}