#include <iostream>
#include <algorithm>
#include <numeric>
using namespace std;
long long buffer[102][10];
int main() {
ios::sync_with_stdio(false);
cin.tie(NULL);
int n;
cin >> n;
buffer[1][0] = 0;
for (int i = 1; i < 10; i++){
buffer[1][i] = 1;
}
if (n > 1) {
for (int i = 2; i <= n; i++) {
for (int j = 0; j < 10; j++) {
if (j == 0) {
buffer[i][0] = buffer[i - 1][1];
} else if (j == 9) {
buffer[i][9] = buffer[i - 1][8];
} else {
buffer[i][j] = (buffer[i - 1][j + 1] + buffer[i - 1][j - 1] )% 1000000000;
}
}
}
}
long long sum = 0;
for (int i = 0; i<10; i++){
sum += buffer[n][i];
}
cout << sum % 1000000000;
return 0;
}