#include<iostream>
#include<string>
#include<cstring>
#include<cmath>
#define ll long long
const long long N = 1e9 + 7;
using namespace std;
long long que(long long n, long long sum) {
long long ans = 1;
while (sum) {
if ( sum & 1)
ans = ans * n % N;
sum >>= 1;
n = n * n % N;//n可能会爆N,所以要取余
}
return ans;
}
int main() {
int n;
cin >> n;
long long sum = 0;
for (int i = 0; i < n; i ++)sum += 1ll * pow(4, i);//int类型和long long 类型做运算是必须要加上long long
sum --;
long long ans = que(4, sum) * 6ll % N;
cout << ans << endl;
}
本题主要考的是数学知识和快速幂