/**
* FWP, Ausgewählte Probleme aus dem
ACM Programming Contest, SS10
* Problem: 10783 Odd Sum
*
Link:
http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&category=19&problem=1724&mosmsg=Submission+received+with+ID+7916994
* @author Viktoriya Ryabova
* @version 1.0, 04/22/2010
*
* Method : Ad-Hoc
* Status : accepted
* Runtime: 0.128
*/
import
java.util.Scanner;
public class Main {
/**
* @param args
*/
public static
void main(String[] args) {
//
TODO Auto-generated method stub
Scanner
sc
= new
Scanner(System.in);
//wie viele fälle
int
count=Integer.parseInt(sc.nextLine());
//nummer des falles
int i=1;
while(count>0){
//zahlen einlesen
int a =
Integer.parseInt(sc.nextLine());
int b
=Integer.parseInt(sc.nextLine());
if(a<=b &&
(a>=0&&b<=100)){
System.out.println("Case "+i+":
"+oddSum(a,b));
}
count--;
i++;
}
}
public static
int oddSum (int a,
int b){
int sum=0;
//Summe
von ungeraden zahlen
berechnen
for(int i=a;
i<=b; i++ ){
if(i%2!=0)sum+=i;
}
//System.out.println(sum);
return sum;
}
}