#include "stdafx.h"
#include "math.h"
#include <iostream>
using namespace std;
double foo (double x, double eps, double a)
{
double func=1.0+a*x;
double mult_x = x;
double up = a;
double q=100.0;
double fact = 1.0;
int i=1;
int m=2;
while( abs(func-q) >= eps)
{ q=func;
fact*=++i;
mult_x*=x;
up*=(a-m+1);
m++;
func+=mult_x*up/fact;
}
return func;
}
void main()
{
double x, eps,a;
cin>>x;
cin>>eps;
cin>>a;
if ((x>-1) && (x<1)) cout<<pow(1+x,a)<<'\t'<<foo(x,eps,a);
else cout<<"otstan Guzhov";
}