/* HDU 2085 核反应堆 --- 简单递推 */
#include <cstdio> const int N = ;
long long a[N], b[N]; //a表示高能质点数目,b表示低能质点数目 int main()
{
#ifdef _LOCAL
freopen("D:\\input.txt", "r", stdin);
#endif
//质点数目初始化
a[] = ;b[] = ;
for (int i = ; i <= ; ++i){
a[i] = * a[i - ] + * b[i - ];
b[i] = a[i - ] + b[i - ];
}
int n;
while (scanf("%d", &n) == && n != -){
printf("%lld, %lld\n", a[n], b[n]);
} return ;
}