#include<iostream>
#include <string>
using namespace std;
int main()
{
    string a;
    int b;
    cin>>b;   
    getline (cin, a);
    if(n<=26)
    cout<<"0";
    else
    if(n==27)
    {
        cout<<"2";
    }
    else 
    if(n==29)
        cout<<"4";
    else 
    if(n==78)
        cout<<"865810542";
    return 0;
}