#include #include #include #include #include #include #include #include #include #include #include #include #include #include #define all(x) (x).begin(),(x).end() #define rall(x) (x).rbegin(),(x).rend() using namespace std; typedef long long ll; typedef pair pi; typedef pair pl; typedef pair plc; ll mod = (ll)(1e9 + 7); ll power(ll x, ll n) { ll tmp = 1; if (n > 0) { tmp = power(x, n / 2); if (n % 2 == 0)tmp = (tmp*tmp) % mod; else tmp = (((tmp*tmp) % mod)*x) % mod; } return tmp; } int main() { ll ans = 1; ll n; cin >> n; if (n == 1) { cout << 2 << endl; return 0; } if (n % 2 != 0)ans = 12 * power(5, n/2-1); else ans = 4 * power(5, n/2-1); cout << ans%mod << endl; return 0; }