Problem:
Score: 600 points

Problem Statement

How many strings can be obtained by applying the following operation on a string S exactly K times: "choose one lowercase English letter and insert it somewhere"?

The answer can be enormous, so print it modulo (10^9+7).

Constraints

K is an integer between 1 and 10^6 (inclusive).

S is a string of length between 1 and 10^6 (inclusive) consisting of lowercase English letters.

Input

Input is given from Standard Input in the following format:

K
S

Output

Print the number of strings satisfying the condition, modulo (10^9+7).

Sample Input 1

5
oof

Sample Output 1

575111451

For example, we can obtain proofend, moonwolf, and onionpuf, while we cannot obtain oofsix, oofelevennn, voxafolt, or fooooooo.

Sample Input 2

37564
whydidyoudesertme

Sample Output 2

318008117

Solution in C (GCC 9.2.1) (judge verdict: Wrong Answer)

#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#include<math.h>
#define ll long long
#define mod 1000000007

char s[1123456];
ll k;

ll pom(ll a,ll n,int m){ll x=1;for(a%=m;n;n/=2)n&1?x=x*a%m:0,a=a*a%m;return x;}

int main(){
  scanf("%lld",&k);
  scanf("%s",s);

  ll naga=strlen(s);
  ll ans=1;
  ll tmp;
  ll waru=1;
  for(ll i=0;i<k;i++){
    tmp = naga*25%mod + 26;
    tmp %= mod;
    ans = ans*tmp%mod;
    naga++;
    waru *= pom(i+1,mod-2,mod);
    waru %= mod;}
  ans = ans*waru%mod;
  
  printf("%lld\n",ans);
  
  return 0;
}