Harryxun/stf_run huggingface dataset:
N, M = map(int, input().split())
a = [int(input())for i in range(M)]
a.sort()
pattern = []
ans = 1

# フィボナッチ数列の関数
def fibonacci(n):
    a, b = 0, 1
    for i in range(n):
        a, b = b, a + b
    return b

# 段の切れ目ごとの場合の数を算出
R = len(a) - 1
for i in range(R):
    x = a[i + 1] - a[i] -1
    pattern.append(fibonacci(x))

# 段の切れ目ごとの場合の数の積
for i in range(len(pattern)):
    ans = ans * pattern[i] % 1000000007

# 1段目まで、最終弾までの数
s1 = fibonacci(a[0])
s2 = fibonacci(N - a[-1])

# かける
ans = ans * s1 * s2 % 1000000007

# 2弾続けて壊れている場合はNG
for i in range(M - 1):
    if a[i] + 1 == a[i + 1]:
        ans = 0

print(ans)


### FIXED CODE ###

N, M = map(int, input().split())
a = [int(input())for i in range(M)]
MOD = 10 ** 9 + 7
ans = []
dp = [1] * (N + 1)

for i in a:
    dp[i] = 0

for i in range(2, N + 1):
    if dp[i] != 0:
        dp[i] = (dp[i - 1] + dp[i - 2])

print(dp[N] % MOD)
a = input()
a[4] = '8'
print(a)

### FIXED CODE ###

a = input()
print('2018' + a[4:])
N = int(input())

H = list(map(int, input().split()))

num_ryokan = 0
max_height = 0

for i in range(N):
  if max_height <= H[i]:#見えるとき
    num_ryokan +=1
    max_height = H[i]

print(num_ryokan)

### FIXED CODE ###

A,B = map(int, input().split())

if A==B:
  print(A+B)
else:
  print(max(A,B)*2-1)
a,b = map(int,input().split())
dif = b-a 
temp = 0
for i in range(dif):
    temp += i 
ans = temp - a
print(ans)

### FIXED CODE ###

n = int(input())
if n<1000:
    print("ABC")
else:
    print("ABD")
import numpy as np
N, M= map(int, input().split())

A = [int(input()) for i in range(N)]


B = []
for i in range(len(A)):
    if A[i] > sum(A)/4/M:
        B.append(0)
    else:
        B.append(1)

if sum(B) > N - M + 1:
    print('No')
else:
    print('Yes')


### FIXED CODE ###


N, M= map(int, input().split())

C = map(int, input().split())

A = list(C)

#if N < M:
#    print('No')
#if M == 0:
#    print('No')

B = []
for i in range(len(A)):
    if A[i] >= sum(A)/4/M:
        B.append(1)
    else:
        B.append(0)

if sum(B) >= M:
    print('Yes')
else:
    print('No')
import numpy as np

N=int(input())
A =list(map(int,input().split()))
flag=False

ans=0
A.sort()

f=[0]*1000005

for i in A:
    f[i]+=1

for i in range(1,1000001,1):
    if f[i]==0:
        continue
    j=i+i
    while j<=1000000:
        f[j]+=f[i]
        j=j+i

for i in A:
    if f[i]==1:
        ans+=1


print(ans)

### FIXED CODE ###

N=int(input())
A =list(map(int,input().split()))
flag=False

ans=0
A.sort()

f=[0]*1000005

for i in A:
    f[i]+=1

for i in range(1,1000001,1):
    if f[i]==0:
        continue
    j=i+i
    while j<=1000000:
        f[j]+=f[i]
        j=j+i

for i in A:
    if f[i]==1:
        ans+=1


print(ans)
def dis(p1,p2):
  return ((p1[0]-p2[0])**2+(p1[1]-p2[0])**2)**0.5

n=int(input())
p=[list(map(int,input().split())) for i in range(n)]
ans=0
fac=1
for i in range(n):
  for j in range(i+1,n):
    ans+=dis(p[i],p[j])
  fac*=i
print(ans*(2n-2)/fac)


### FIXED CODE ###

def dis(p1,p2):
  return ((p1[0]-p2[0])**2+(p1[1]-p2[1])**2)**0.5

n=int(input())
p=[list(map(int,input().split())) for i in range(n)]
ans=0
for i in range(n):
  for j in range(i+1,n):
    ans+=dis(p[i],p[j])
print(ans*2/n)
import sys
import math
import itertools
import collections
import heapq
import re
import numpy as np

rr = lambda: sys.stdin.readline().rstrip()
rs = lambda: sys.stdin.buffer.readline().split()
ri = lambda: int(sys.stdin.readline())
rm = lambda: map(int, sys.stdin.buffer.readline().split())
rl = lambda: list(map(int, sys.stdin.readline().split()))
inf = float('inf')
mod = 10**9 + 7

a, v = rm()
b, w = rm()
t = ri()
if ((b-a) / (v-w)) % t == 0:
  print('YES')
else:
  print('NO')



### FIXED CODE ###

import sys
import math
import itertools
import collections
import heapq
import re
import numpy as np

rr = lambda: sys.stdin.readline().rstrip()
rs = lambda: sys.stdin.buffer.readline().split()
ri = lambda: int(sys.stdin.readline())
rm = lambda: map(int, sys.stdin.buffer.readline().split())
rl = lambda: list(map(int, sys.stdin.readline().split()))
inf = float('inf')
mod = 10**9 + 7

a, v = rm()
b, w = rm()
t = ri()
if v - w == 0:
  print('NO')
  exit()
if 0 <= abs(a-b) / (v-w) <= t:
  print('YES')
else:
  print('NO')
n=int(input())
a=list(map(int,input().split()))
aa=set(a)
if len(aa)>3:
    print("No")
    exit()
elif a.count(0)==n:
    print("Yes")
    exit()
elif len(aa)<=1:
    print("No")
    exit()
l=[]
l.append(a[0])
for i in range(1,n):
    if a[i]!=a[0]:
        l.append(a[i])
        break
l.append(l[0]^l[1])

if n==0:
    exit()
else:
    if l[0]==l[1]:
        if n%3==0:
            if a.count(l[0])==(n//3)*2 and a.count(l[2])==n//3:
                print("Yes")
            else:
                print("No")
        else:
            print("No")
    if l[0]==l[2]:
        if n%3==0:
            if a.count(l[0])==(n//3)*2 and a.count(l[1])==n//3:
                print("Yes")
            else:
                print("No")
        elif n%==1:
            if a.count(l[0])==(n//3)*2+1 and a.count(l[1])==n//3:
                print("Yes")
            else:
                print("No")
        else:
            print("No")
    if l[2]==l[1]:
        if n%3==0:
            if a.count(l[1])==(n//3)*2 and a.count(l[0])==n//3:
                print("Yes")
            else:
                print("No")
        elif n%3==2:
            if a.count(l[0])==(n//3)*2+1 and a.count(l[0])==n//3+1:
                print("Yes")
            else:
                print("No")
        else:
            print("No")
    else:
        if n%3==0:
            if a.count(l[0])==n//3 and a.count(l[1])==n//3 and a.count(l[2])==n//3:
                print("Yes")
            else:
                print("No")
        else:
            print("No")


### FIXED CODE ###

n=int(input())
a=list(map(int,input().split()))
aa=set(a)
if len(aa)>3:
    print("No")
    exit()
elif a.count(0)==n:
    print("Yes")
    exit()
elif len(aa)<=1:
    print("No")
    exit()
l=[]
l.append(a[0])
for i in range(1,n):
    if a[i]!=a[0]:
        l.append(a[i])
        break
l.append(l[0]^l[1])

if n==0:
    exit()
else:
    if len(aa)==2:
        if n%3==0:
            if (a.count(l[0])==(n//3)*2 and a.count(l[1])==n//3) or (a.count(l[1])==(n//3)*2 and a.count(l[0])==n//3):
                print("Yes")
            else:
                print("No")
        elif n%3==1:
            if (a.count(l[0])==(n//3)*2+1 and a.count(l[1])==n//3) or (a.count(l[1])==(n//3)*2 and a.count(l[0])==n//3+1):
                print("Yes")
            else:
                print("No")
        elif n%3==2:
            if (a.count(l[0])==(n//3)*2+1 and a.count(l[1])==n//3+1) or (a.count(l[1])==(n//3)*2+1 and a.count(l[0])==n//3+1):
                print("Yes")
            else:
                print("No")


    else:
        if n%3==0:
            if a.count(l[0])==n//3 and a.count(l[1])==n//3 and a.count(l[2])==n//3:
                print("Yes")
            else:
                print("No")
        else:
            print("No")
s = raw_input()
k = input()
index = -1
for i in xrange(len(s)):
	if s[i] > '1':
		index = i
		break
index += 1
if k >= index:
	print s[index]
else:
	print 1

### FIXED CODE ###

s = raw_input()
k = input()
index = -1
for i in xrange(len(s)):
	if s[i] > '1':
		index = i
		break
index += 1
if k >= index:
	print s[index-1]
else:
	print 1
a=[]
for i in range(3):
	a.append(int(input()))
a.sort()
if a[2]-a[1]==a[1]-a[0]:
	print('YES')
else:
	print('NO')

### FIXED CODE ###

a,b,c=input().split()
d=[]
d.append(int(a))
d.append(int(b))
d.append(int(c))
if d[2]-d[1]==d[1]-d[0]:
	print('YES')
else:
	print('NO')
n = int(input())
a = list(map(int, input().split()))
a.sort()
c = [0]*len(a)
cnt = len(a)
k = 1
for e in a:
  if c[k]==1:
    continue
  for i in range(k, len(a)):
    if a[i]%e!=0:
      continue
    else:
      c[i] = 1
      cnt -= 1
  k +=1
if c[1]==1 and a[0]!=0:
  print(0)
else:
  print(cnt)

### FIXED CODE ###

n = int(input())
a = list(map(int, input().split()))
a.sort()
dp = [0]*(1000000+1)
cnt = 0
for i in range(len(a)):
  if dp[a[i]]==1:
    continue
  j = 2
  while(a[i]*j<=a[-1]):
    dp[a[i]*j] = 1
    j += 1
  if i!=len(a)-1 and a[i+1]==a[i]:
    dp[a[i]] = 1
    continue
  cnt += 1
  dp[a[i]] = 1
print(cnt)
N = int(input())
    flag = 0
    
    for i  in range(9):
        atai = N / (i + 1) 
        for j in range(9):
            if atai == j + 1:
                flag = 1
                break
        if flag == 1:
            break
    if flag == 1:
        print("Yes")
    else:
        print("No")


### FIXED CODE ###

N = int(input())
flag = 0

for i  in range(9):
    atai = N / (i + 1) 
    for j in range(9):
        if atai == j + 1:
            flag = 1
            break
    if flag == 1:
        break
if flag == 1:
    print("Yes")
else:
    print("No")
x = input()
y = input()

if x < y:
    print('<')
elif y < x:
    print('>')
else:
    print('=')


### FIXED CODE ###

a = list(input())
x = a[0]
y = a[2]

if x < y:
    print('<')
elif y < x:
    print('>')
else:
    print('=')
using System;
using System.Text;
using System.Linq;
using System.Collections;
using System.Collections.Generic;
using static System.Console;
using static System.Math;

namespace AtCoder
{
    public class Program
    {
        public static void Main(string[] args)
        {
            new Program().Solve(new ConsoleInput(Console.In, ' '));
        }

        public void Solve(ConsoleInput cin)
        {
            int N = cin.ReadInt;
            var AB = new int[N][];
            for(int i=0;i<N;i++){
                AB[i] = cin.ReadIntArray(2);
            }
            var ABs = AB.OrderBy(x => x[1]);
            long curtime = 0;
            string ans = "Yes";
            foreach(int[] L in ABs){
                curtime += L[0];
                if(curtime > L[1]){
                    ans = "No";
                    break;
                }
            }
            WriteLine(ans);
        }
    }

    public class ConsoleInput
    {
        private readonly System.IO.TextReader _stream;
        private char _separator =' ';
        private Queue<string> inputStream;
        public ConsoleInput(System.IO.TextReader stream, char separator = ' ')
        {
            this._separator = separator;
            this._stream = stream;
            inputStream = new Queue<string>();
        }
        public string Read
        {
            get
            {
                if (inputStream.Count != 0) return inputStream.Dequeue();
                string[] tmp = _stream.ReadLine().Split(_separator);
                for (int i = 0; i < tmp.Length; ++i)
                    inputStream.Enqueue(tmp[i]);
                return inputStream.Dequeue();
            }
        }
        public string ReadLine { get { return _stream.ReadLine(); }}
        public int ReadInt { get { return int.Parse(Read); }}
        public long ReadLong { get { return long.Parse(Read); }}
        public double ReadDouble { get { return double.Parse(Read); }}
        public string[] ReadStrArray(long N) { var ret = new string[N]; for (long i = 0; i < N; ++i) ret[i] = Read; return ret;}
        public int[] ReadIntArray(long N) { var ret = new int[N]; for (long i = 0; i < N; ++i) ret[i] = ReadInt; return ret;}
        public long[] ReadLongArray(long N) { var ret = new long[N]; for (long i = 0; i < N; ++i) ret[i] = ReadLong; return ret;}
    }
}


### FIXED CODE ###

N=int(input())
AB = [[int(i) for i in input().split()] for j in range(N)]
ABDeadStart = [[A,B,B-A] for A,B in AB]#所要時間、初めてないと駄目な時間
MaxShoyou = sum([a for a,b,kaisi in ABDeadStart])
ABDeadStart.sort(key = lambda x:x[2]-MaxShoyou+x[0])
curtime = 0
NO =0
for a,b,ds in ABDeadStart:
    if curtime <= ds:
        curtime += a
    else:
        NO =True
        break
if NO :print("No")
else:print("Yes")
A, B, M = map(int, input().split())
a = [int(i) for i in input().split]
b = [int(i) for i in input().split]

ans = min(a) + min(b)

for i in range(M):
  x, y, c = map(int, input().split())
  val = a[x-1] + b[y-1] - c
  ans = min(ans, val)
print(ans)


### FIXED CODE ###

A, B, M = map(int, input().split())
a = [int(i) for i in input().split()]
b = [int(i) for i in input().split()]

ans = min(a) + min(b)

for i in range(M):
  x, y, c = map(int, input().split())
  val = a[x-1] + b[y-1] - c
  ans = min(ans, val)
print(ans)
N, A, B = map(int, input().split())
an = N // (A+B) * A
rem = N % (A+B)
an += min(rem,A)
print(ans)

### FIXED CODE ###

N, A, B = map(int, input().split())
an = N // (A+B) * A
rem = N % (A+B)
an += min(rem,A)
print(an)
N = int(input())
print(((N//2)+1)/2N if N%2 != 0 else 0.5 )


### FIXED CODE ###

N = int(input())
print(((N//2)+1)/N if N%2 != 0 else "0.5" )
X = int(S[0])+int(S[1])
Y = int(S[0])-int(S[1])
Z = int(S[0])*int(S[1])
intS[0] = ss
intS[1] = dd
if X >= Y:
    if X >= Z:
        print(X)
    else:
        print(Z)
else:
    if Y >= Z:
        print(Y)
    else:
        print(Z)

### FIXED CODE ###


S = input().split()
X = int(S[0])+int(S[1])
Y = int(S[0])-int(S[1])
Z = int(S[0])*int(S[1])
if X >= Y:
    if X >= Z:
        print(X)
    else:
        print(Z)
else:
    if Y >= Z:
        print(Y)
    else:
        print(Z)
x,y=map(int,raw_input().split())
a=[1,3,5,7,8,10,12]
b=[4,6,9,11]
c=[2]
for i in range(1000):
  if a[i]==x and a[i]==y:
    print "Yes"
  elif b[i]==x and b[i]==y:
    print "Yes"
  else:
    print "No"

### FIXED CODE ###

a=[1,3,5,7,8,10,12]
b=[4,6,9,11]
c=[2]
x,y=map(int,raw_input().split())
ans= "No"
if x in a and y in a:
  ans= "Yes"
elif x in b and y in b:
  ans = "Yes"
print ans
N = input()
if 7 in N:
  print('Yes')
else:
  print('No')

### FIXED CODE ###

N = input()
if ('7' in N):
  print('Yes')
else:
  print('No')
import sys
sys.setrecursionlimit(10000000)
input = sys.stdin.readline
from bisect import *
from collections import *
from heapq import *
import functools
import itertools
import math
INF = float('inf')
MOD = 10**9+7

# Range Minimum query
class SegmentTree:

    def __init__(self, N, INF = INF):
        self.N = 1
        while self.N < N:
            self.N *= 2
        self.data = [INF for i in range(self.N*2-1)]

    def update(self, k, a):
        k += self.N-1
        self.data[k] = a
        while k > 0:
            k = (k-1)//2
            self.data[k] = min(self.data[k*2+1], self.data[k*2+2])

    def RmQ(self, a, b, k=0, l=0, r=-1):
        if r == -1: r = self.N
        if r <= a or b <= l:
            return INF
        if a <= l and r <= b:
            return self.data[k]
        vl = self.RmQ(a, b, k*2+1, l, (l+r)>>1)
        vr = self.RmQ(a, b, k*2+2, (l+r)>>1, r)
        return min(vl, vr)

N, M = map(int, input().split())
S = input()
dp = SegmentTree(N+1)
dp.update(0, 0)
for i in range(1, N+1):
    if S[i] == '0':
        c = dp.RmQ(max(0, i-M), i)
        if c != INF:
            dp.update(i, c+1)
G = dp.RmQ(N, N+1)
if G == INF:
    print(-1)
    exit()
minv = [INF] * N
for i in range(N)[::-1]:
    if S[i] == '0':
        x = dp.RmQ(i, i+1)
        minv[x] = i
minv[G] = N
x = 0
vs = []
while x <= G:
    vs.append(minv[x])
    x += 1
vs = vs[::-1]
ans = [vs[i]-vs[i+1] for i in range(len(vs)-1)]
print(*ans[::-1], sep = ' ')


### FIXED CODE ###

import sys
sys.setrecursionlimit(10000000)
input = sys.stdin.readline
from bisect import *
from collections import *
from heapq import *
import functools
import itertools
import math
INF = float('inf')
MOD = 10**9+7

def dijkstra_path(s, edges):
    dist = [INF for i in range(len(edges))]
    dist[s], h, p = 0, [], [-1]*len(edges)
    heappush(h, (0, s))
    while (len(h)):
        dv, v = heappop(h)
        if dv > dist[v]:
            continue
        for u, cost in edges[v]:
            tmp = dv+cost
            if tmp < dist[u]:
                dist[u] = tmp
                p[u] = v
                heappush(h, (tmp, u))
    return dist, p

N, M = map(int, input().split())
S = input()
ids = []
for i, x in enumerate(S):
    if x == '0':
        ids.append(-i)
ids = ids[::-1]
l = len(ids)
es = [[] for i in range(N+1)]
for i in range(N, 0, -1):
    es[i].append((-ids[min(l-1, bisect_right(ids, -i+M)-1)], 1))
d, p = dijkstra_path(N, es)
if d[0] == INF:
    print(-1)
    exit()
vs = []
v = 0
while v != -1:
    vs.append(v)
    v = p[v]
ans = [vs[i+1]-vs[i] for i in range(len(vs)-1)]
print(*ans, sep = ' ')
N, M, K = map(int,input().split())
A = list(map(int,input().split()))
B = list(map(int,input().split()))

sumA = []
sumB = []
tmp = 0
answer = 0
st = 1

for i in range(N):
    tmp = tmp + A[i]
    sumA.append(tmp)

tmp = 0
for i in range(M):
    tmp = tmp + B[i]
    sumB.append(tmp)

for i in range(N, 0, -1):
    booktmp = 0

    for j in range(st , M + 1):

        if sumA[i-1] + sumB[j-1] <= K:
            booktmp = i + j
            st = st + 1
        else:
            st = st - 1
            break
    answer = max(answer, booktmp)


print(answer)




### FIXED CODE ###

N, M, K = map(int,input().split())
A = list(map(int,input().split()))
B = list(map(int,input().split()))

sumA = [0]
sumB = [0]
tmp = 0
answer = 0
st = 0

for i in range(N):
    tmp = tmp + A[i]
    sumA.append(tmp)

tmp = 0
for i in range(M):
    tmp = tmp + B[i]
    sumB.append(tmp)

for i in range(N, -1, -1):
    booktmp = 0

    for j in range(st, M + 1):

        if sumA[i] + sumB[j] <= K:
            booktmp = i + j
        else:
            st = j
            break
    answer = max(answer, booktmp)
    if j == M:
        break


print(answer)
mod = 10 ** 9 + 7

N, K = map(int, input().split())

dp = [[[0 for _ in range(2510)] for _ in range(51)] for _ in range(51)]
dp[0][0][0] = 1

for i in range(N):
    for j in range(N):
        for k in range(K + 1):
            dp[i + 1][j + 1][k + 2 * j + 2] += dp[i][j][k]
            if j > 0:
                dp[i + 1][j][k + 2 * j] += dp[i][j][k] * j
                dp[i + 1][j][k + 2 * j] += dp[i][j][k] * j

            dp[i + 1][j][k + 2 * j] += dp[i][j][k]

            if j > 0:
                dp[i + 1][j - 1][k + 2 * j - 2] += dp[i][j][k] * j * j


print(dp[N][0][K] % mod)

### FIXED CODE ###

mod = 10 ** 9 + 7

N, K = map(int, input().split())

dp = [[[0 for _ in range(2610)] for _ in range(51)] for _ in range(51)]
dp[0][0][0] = 1

for i in range(N):
    for j in range(N):
        for k in range(K + 1):
            dp[i + 1][j + 1][k + 2 * j + 2] += dp[i][j][k]
            if j > 0:
                dp[i + 1][j][k + 2 * j] += dp[i][j][k] * j
                dp[i + 1][j][k + 2 * j] += dp[i][j][k] * j

            dp[i + 1][j][k + 2 * j] += dp[i][j][k]

            if j > 0:
                dp[i + 1][j - 1][k + 2 * j - 2] += dp[i][j][k] * j * j


print(dp[N][0][K] % mod)
import sys
input = sys.stdin.readline

N = int(input())
l = [int(input())]

for i in range(N-1):
  ai = int(input())
  flag = False
  for m in l:
    if max(m) < ai:
      m.append(ai)
      flag = True
      break
  if flag == False:
    l.append([ai])
    
print(len(l))

### FIXED CODE ###

import sys
input = sys.stdin.readline
from bisect import bisect_right

N = int(input())
l = [-int(input())]

for i in range(N-1):
  ai = -int(input())
# 各色の最大値がlの要素になるようにリストを拡大させていく
  if l[-1] <= ai:
    l.append(ai)
  else:
    b = bisect_right(l, ai)
    l[b] = ai
    
print(len(l))
import sys
import math
def I():return int(sys.stdin.readline().replace("\n",""))
def I2():return map(int,sys.stdin.readline().replace("\n","").split())
def S():return str(sys.stdin.readline().replace("\n",""))
def L():return list(sys.stdin.readline().replace("\n",""))
def Intl():return [int(k) for k in sys.stdin.readline().replace("\n","").split()]
def Lx(k):return list(map(lambda x:int(x)*-k,sys.stdin.readline().replace("\n","").split()))

n = I()
a = Intl()
cnt = 0
a = a[::-1]
now = a[0]
#print(now,a)
for i in range(1,n):
    if a[i] >= now:
        cnt += 1
    else if now-1 == a[i]:
        now = a[i]
    else:
        cnt += 1
print(cnt if now == 1 else -1)

### FIXED CODE ###

import sys
import math
def I():return int(sys.stdin.readline().replace("\n",""))
def I2():return map(int,sys.stdin.readline().replace("\n","").split())
def S():return str(sys.stdin.readline().replace("\n",""))
def L():return list(sys.stdin.readline().replace("\n",""))
def Intl():return [int(k) for k in sys.stdin.readline().replace("\n","").split()]
def Lx(k):return list(map(lambda x:int(x)*-k,sys.stdin.readline().replace("\n","").split()))

n = I()
a = Intl()
cnt = 0
if not 1 in a:
    print(-1)
    exit()
now = 1
for i in range(n):
    if now == a[i]:
        now += 1
    else:
        cnt += 1
print(cnt)
while True: 
(H, W) = [int(x) for x in input().split()]
if H == W == 0:
    break

print((('#' * W) + '\n') * H)

### FIXED CODE ###

while True:
    H,W = map(int, input().split())
    if W == H == 0:
        break;
    L="#"*W
    for i in range(H):
        print(L)
    print("")
a,b = map(iny.input(),split())
print(a*b)

### FIXED CODE ###

a,b = map(int,input().split())
print(a*b)
import fractions
n=int(input())
lists=[]
glmlists=[]
for s in range(n):
    s=int(input())
    lists.append(s)
lists.append(1)
glm=lists[0]
cnt=0
while cnt<n:
    gcd=fractions.gcd(glm,lists[cnt+1])
    glm=int(glm*lists[cnt+1]/gcd)
    glmlists.append(glm)
    cnt+=1    
print(glmlists[-1])

### FIXED CODE ###

#早くmathを導入してほしい
from fractions import gcd
n=int(input())
glm=1
for i in range(n):
    nums=int(input())
    glm=int(glm*nums//gcd(nums,glm))
print(glm)
R,G = map (int, input(). split())
print (2*G-R)

### FIXED CODE ###

R = int(input())
G = int(input())

print (2*G-R)
import sys
n, k = map(int, sys.stdin.readline().split())
li = list(map(int, sys.readline().split()))
cnt = 0
for i in li:
  if i >= k:
    cnt += 1
print(cnt)

### FIXED CODE ###

import sys
n, k = map(int, sys.stdin.readline().split())
li = list(map(int, sys.stdin.readline().split()))
cnt = 0
for i in li:
  if i >= k:
    cnt += 1
print(cnt)