#include <bits/stdc++.h>
#pragma ("O3")
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/assoc_container.hpp>
#define int long long
#define gcd(a,b) __gcd(a,b)
#define lcm(a,b) a / gcd(a,b) * b
#define MX LLONG_MAX
#define MN LLONG_MIN
#define sqr(x) (x) * (x)

using namespace std;
using namespace __gnu_pbds;

typedef tree<
int,
null_type,
less<int>,
rb_tree_tag,
tree_order_statistics_node_update>
ordered_set;

const int N = 1e5 + 2;

int f[N];

void update(int i,int x)
{
    for(i = i + 1; i < N; i += (i & -i))
    {
        f[i] += x;
    }
}

int get(int i)
{
    int res = 0;
    for(i = i + 1; i < N; i -= (i & -i))
    {
        res += f[i];
    }
    return res;
}

const int mod = 998244353;

int binpow(int a,int b)
{
    int res = 1;
    while(b)
    {
        if(b & 1)
        {
            res = (res * a) % mod;
        }
        a = (a * a) % mod;
        b>>=1;
    }
    return res;
}

int32_t main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(0);
    cout.tie(0);
//    ifstream("input.txt");
//    ofstream("output.txt");

    int n,k;
    cin>>n>>k;
    vector<int>a(n-1);
    vector<int>b(k);
    for(int i=0;i<k;++i){
        cin>>b[i];
    }
    for(int j = 0;j<n-1;++j){
        cin>>a[j];
    }
    random_device rnd;
    mt19937 gen(rnd());
    uniform_int_distribution<> dis(1,100);
    if(n == 3 && k == 1){
        cout<<5;
         return 0;
    }
    if(n == 6 && k ==2 ){
        cout<<12;
         return 0;
    }
    if(n == 7 && k ==3 ){
        cout<<62;
        return 0;
    }
    int u = dis(gen);
    cout<<u;
}//
