#include <bits/stdc++.h>
using namespace std;
int main() {
  int p1, p2, p3;
  scanf("%d%d%d", &p1, &p2, &p3);
  if (p3 == 1) {
    cout << p2 << endl;
    return 0;
  }
  int l1 = p1, l2 = p2, l3;
  for (int i = 1; i <= p3 - 1; ++i) {
    l1 = p2;
    p2 += p1;
    p1 = l1;
  }
  cout << p2 << endl;
  return 0;
}
