#include <bits/stdc++.h>
using namespace std;
int a, b, c;
int main() {
  cin >> a >> b >> c;
  if (c == 1) {
    cout << b << endl;
    return 0;
  }
  int d;
  for (int i = 0; i < c - 1; i++) {
    d = a + b;
    a = b;
    b = d;
  }
  cout << d << endl;
}
