#include <iostream>
using namespace std;

int fairfield(int y, int m, int d) {
	if (m < 3) {
		--y;
		m += 12;
	}
	return 365 * y + (y / 4) - (y / 100) + (y / 400) + (306 * (m + 1) / 10) + d - 428;
}

int main () {
	int y1, m1, d1, y2, m2, d2;
	while (cin >> y1 >> m1 >> d1 >> y2 >> m2 >> d2, y1 > 0) {
		cout << fairfield(y2, m2, d2) - fairfield(y1, m1, d1) << endl;
	}
	return 0;
}