#include
using namespace std;
int main()
{
int mint = 0, maxt = 0, step = 0, temp = 0;
cin >> mint;
cin >> maxt;
cin >> step;
//cout << mint << " " << int ((mint - 32) * 0.55) << endl;
int nstep = mint;
while (nstep <= maxt)
{
cout << nstep << "\t" << int ((nstep - 32) * 0.55) << endl;
nstep += step;
}
return 0;
}