#include <iostream>
using namespace std;
int main() {
int T, a, b;
while ( cin >> T ) {
for ( int t = 1; t <= T; ++t ) {
cin >> a >> b;
int sum = 0;
for ( int i = a; i <= b; ++i ) {
if ( i & 1 )
sum += i;
}
cout << "Case " << t << ": " << sum << endl;
}
}
return 0;
}