#include <iostream>
#include <iomanip>
#include <cmath>
using namespace std;
int cs=1;
int main(){
ios::sync_with_stdio(0);
while(1){
int r,n;
cin>>r>>n;
if(!(r||n))
return 0;
cout<<"Case "<<cs++<<": ";
if(!n){
cout<<"impossible"<<endl;
continue;
}
int quo=r/n,rem=r%n;
quo--;
if(rem)
quo++;
if(quo>26)
cout<<"impossible"<<endl;
else
cout<<quo<<endl;
}
}
#include <iomanip>
#include <cmath>
using namespace std;
int cs=1;
int main(){
ios::sync_with_stdio(0);
while(1){
int r,n;
cin>>r>>n;
if(!(r||n))
return 0;
cout<<"Case "<<cs++<<": ";
if(!n){
cout<<"impossible"<<endl;
continue;
}
int quo=r/n,rem=r%n;
quo--;
if(rem)
quo++;
if(quo>26)
cout<<"impossible"<<endl;
else
cout<<quo<<endl;
}
}
Comments
Post a Comment