Felix6326727/beyond-accuracy-code-comprehension huggingface dataset:
def selection_sort(array):
    count_swap = 0
    for i in range(len(array)):
        minj = i
        for j in range(i + 1,len(array)):
            if num(array[j]) < num(array[minj]):
                minj = j
        if num(array[minj]) is not num(array[i]):
            tmp = array[minj]
            array[minj] = array[i]
            array[i] = tmp
            count_swap += 1
    return count_swap

def bubble_sort(array):
    isEnd = False
    count_swap = 0
    while isEnd is False:
        isEnd = True
        for j in reversed(range(1,len(array))):
            if num(array[j - 1]) > num(array[j]):
                tmp = array[j - 1]
                array[j - 1] = array[j]
                array[j] = tmp
                count_swap += 1
                isEnd = False
    return count_swap

def print_array(array):
     print(str(array)[1:-1].replace(', ', ' ').replace('\'', ''))

def num(s):
    # print(s[1])
    return int(s[1])

def main():
    N = int(input())
    array = [s for s in input().split(' ')]
    array2 = [i for i in array]
    # print(array)
    bubble_sort(array)
    print_array(array)
    print('Stable')
    selection_sort(array2)
    print_array(array2)
    if array == array2:
        print('Stable')
    else:
        print('Not stable')

if __name__ == '__main__':
    main()

# Example run
# Input:
14319043
15927431
# Output:
15927431
Stable
15927431
Stable
c = list(map(int, input().split()))
a = [1,5,10,50,100,500]
print(1 if sum([x * y for (x, y) in zip(c, a)]) >= 1000 else 0)


# Example run
# Input:
-22
# Output:
0
coins = list(map(int, input().split()))
for i in range(len(coins)):
    current_coin = coins[i]
    if i == 0:
        coins[i] = current_coin * 1
    elif i == 1:
        coins[i] = current_coin * 5
    elif i == 2:
        coins[i] = current_coin * 10
    elif i == 3:
        coins[i] = current_coin * 50
    elif i == 4:
        coins[i] = current_coin * 100
    elif i == 5:
        coins[i] = current_coin * 500

if sum(coins) >= 1000:
    print('1')
else:
    print('0')

# Example run
# Input:
57223618
# Output:
1
print(1 if sum([v * (5 if i % 2 else 1) * 10**(i // 2) for i, v in enumerate(list(map(int, input().split())))]) >= 1000 else 0)

# Example run
# Input:
21420
# Output:
1
print(1 if sum([x*y for x,y in zip(list(map(int, input().split())),[1,5,10,50,100,500])])>=1000 else 0)

# Example run
# Input:
2
# Output:
0
coins = list(map(int, input().split()))
for i in range(len(coins)):
    current_coin = coins[i]
    if i == 0:
        coins[i] = current_coin * 1
    elif i == 1:
        coins[i] = current_coin * 5
    elif i == 2:
        coins[i] = current_coin * 10
    elif i == 3:
        coins[i] = current_coin * 50
    elif i == 4:
        coins[i] = current_coin * 100
    elif i == 5:
        coins[i] = current_coin * 500
 
if sum(coins) >= 1000:
    print('1')
else:
    print('0')


# Example run
# Input:
188355
# Output:
1
print(1 if sum((i * j for i , j in zip((1, 5, 10, 50, 100, 500), map(int, input().split())))) >= 1000 else 0)


# Example run
# Input:
23763566
# Output:
1
c = list(map(int, input().split()))
a = [1,5,10,50,100,500]
print(sum([x * y for (x, y) in zip(c, a)]))


# Example run
# Input:
20210157
# Output:
20210157
K = int(input())
S = input()

if len(S) <= 2:
    if K == 0: print(int(S))
    else: print(max(int(S[0]), int(S[1])))
else:
    print(S[0])


# Example run
# Input:
-5
]6ms%5P
# Output:
]
K = int(input())
S = input()

if len(S) <= 2:
    if K == 0: print(int(S))
    else: print(min(int(S[0]), int(S[1])))
else:
    print(S[0])


# Example run
# Input:
5101803
#("Ua
# Output:
#
N = int(input()) %10
hon=[2,4,5,7,9]
bon=[3]

if N in hon:
    print("hon")
elif N in bon:
    print("bon")
else:
    print("pon")


# Example run
# Input:
985477
# Output:
hon
N = int(input())
K = int(input())
result = K
for i in range(N-1) :
    result = result * (K -1)
print(result)

# Example run
# Input:
1
21
# Output:
21
n = int(input())
k = int(input())

ans=1

for i in range(k):
  ans = ans*n
  n -= 1
  
print(ans)

# Example run
# Input:
531
-1185109
# Output:
1
n = int(input())
k = int(input())
val = k;
for i in range(n-1):
  val *= k -1
print(val)

# Example run
# Input:
-1686
14508349
# Output:
14508349
N=int(input())
K=int(input())
print(K*(K-1)**(N-1))

# Example run
# Input:
-330
-2503
# Output:
0.0
a = int(input())
b = int(input())
c = b * (b-1) ** (a-1)
print(c)

# Example run
# Input:
-1929760035
-2147483648
# Output:
-0.0
N = int(input())
K = int(input())

if(N==1):
  	print(K)
else:
	answer = K*(N-1)*(K-1)
	print(answer)

# Example run
# Input:
-2260822
60
# Output:
-8003313420
def I_dont_know_what_to_do():
    n = int(input())
    k = int(input())

    s = k * ((k - 1) ** (n - 1))
    print(s)

I_dont_know_what_to_do()

# Example run
# Input:
12
80731065
# Output:
76645757605360185114174609928640952446198768517585572729763461664004567363696918426258935644160
import math


def inputs(num_of_input):
    ins = [input() for i in range(num_of_input)]
    return ins


def solve(inputs):
    N = int(inputs[0])
    power = 1
    for i in range(1, N + 1):
        power = (i * power) % (10 ** 9 + 7)
    return power


if __name__ == "__main__":
    ret = solve(inputs(1))
    print(ret)

# Example run
# Input:
456242
# Output:
895437368
n = int(input())
k = int(input())

print(k*(k-1)**(n-1))

# Example run
# Input:
-868
2583
# Output:
0.0
x = int(input())

p = int(input())

if x % 2 == 0:
    print (100 * (x//2) / p)
else:
    print ((100 * (x//2+1) / p))


# Example run
# Input:
-15015728
42339391
# Output:
-17.73257437736882
x=int(input())
p=int(input())/100
print((x+1)//2 * 1 / p)

# Example run
# Input:
-34422
388
# Output:
-4435.8247422680415
x = int(input())
p = int(input())
print("%.016f\n" % ((((x+(x%2))/2)*100/p)))

# Example run
# Input:
-25200
460
# Output:
-2739.1304347826085177
x = int(input())
p = int(input())
l = p / 100

def f(d):
    return (d / 2) * 100 / p

if x % 2 == 0:
    res = f(x)
else:
    res = 1 + l * f(x - 1) + (1 - l) * f(x + 1)

print(res)

# Example run
# Input:
103303
1418198351
# Output:
0.0036420857504708692
x = int(input())
p = int(input())
p *= 0.01
print((x+1)//2/p)

# Example run
# Input:
0
1
# Output:
0.0
N = int(input())
M = int(input())
if N%2:
 print(1 + (N-1)  /  2 + (100 - M) * (N+1) /2 / M)
else:
 print(N * 50 / M)

# Example run
# Input:
-20720
-1
# Output:
1036000.0
#!/usr/bin/env python3
import math
x = int(input())
p = int(input())/100
print(math.ceil(x / 2) / p)


# Example run
# Input:
-464240
19804
# Output:
-1172.0864471823875
from sys import exit, setrecursionlimit
from functools import reduce
from itertools import *
from collections import defaultdict
from bisect import bisect

def read():
  return int(input())

def reads():
  return [int(x) for x in input().split()]

setrecursionlimit(1000000)

x = read()
p = read()

p *= 0.01


if x % 2 == 0:
  print((x // 2) / p)
else:
  y = x // 2
  print(1 + p * y / p + (1 - p) * (y + 1) / p)


# Example run
# Input:
28
197766
# Output:
0.007079073248182195
x = int(input())
p = int(input()) / 100
print(((x + 1) // 2) / p)


# Example run
# Input:
837188354
9535340
# Output:
4389.923977540392
n = int(input())
a = int(input())
print((n**2)-a)

# Example run
# Input:
-1799682701
446
# Output:
3238857824278654955
n = int(input())
a = int(input())
print(n**2 - a)

# Example run
# Input:
-4116
-2154
# Output:
16943610
N = int(input())
A = int(input())
print(N*N-A)

# Example run
# Input:
55
715035410
# Output:
-715032385
n_line = int(input())
num_a_painted_white = int(input())

total_space = n_line * n_line
num_a_painted_black = total_space - num_a_painted_white

print(num_a_painted_black)

# Example run
# Input:
-2777886
182
# Output:
7716650628814
n = int(input())
a = int(input())
print(n*n-a)

# Example run
# Input:
160
4487442
# Output:
-4461842
#ABC074A
N = int(input())
A = int(input())
print(N**2-A)

# Example run
# Input:
-194151326
1
# Output:
37694737387558275
N = int(input())
A = int(input())
print(N * N - A)

# Example run
# Input:
47000128
-23891
# Output:
2209012032040275
n = int(input())
a = int(input())
print(n*n - a)

# Example run
# Input:
547
23800
# Output:
275409
n=int(input())
a=int(input())
print(n**2-a)


# Example run
# Input:
-2
-2701677
# Output:
2701681
import math

N=int(input())
A=int(input())

print(N*N-A)

# Example run
# Input:
-5
-2147483648
# Output:
2147483673
n = int(input())
a = int(input())
print(n*n-a)

# Example run
# Input:
-1928286
9062461
# Output:
3718277835335
n = int(input())
a = int(input())

print((n * n) - a)

# Example run
# Input:
-25166
4
# Output:
633327552
N = int(input())
A = int(input())
print(N**2-A)

# Example run
# Input:
23763566
0
# Output:
564707069036356
a=int(input())
b=int(input())
print(a*a-b)

# Example run
# Input:
104248
-291704
# Output:
10867937208
n = int(input())
a = int(input())
print(n*n-a)


# Example run
# Input:
-1
-3439167
# Output:
3439168
n = int(input())
a = int(input())
print(n**2-a)


# Example run
# Input:
-3249
901872
# Output:
9654129
N = int(input())
A = int(input())
print(N**2-A)

# Example run
# Input:
2817
-15415740
# Output:
23351229
N = int(input())
A = int(input())
print(N**2 - A)

# Example run
# Input:
-3550
-11385106
# Output:
23987606
n=int(input())
a=int(input())
print(n*n-a)

# Example run
# Input:
592
-24962
# Output:
375426
a=int(input())
b=int(input())
print(a*a-b)

# Example run
# Input:
-86
0
# Output:
7396
# A - Bichrome Cells
n = int(input())
a = int(input())

print(n ** 2 - a)

# Example run
# Input:
45718
398138
# Output:
2089737386
n=int(input())
a=int(input())
n=pow(n,2)
print(n-a)

# Example run
# Input:
10026
70800
# Output:
100449876
#!/usr/bin/python3

n = int(input())
a = int(input())

print(n ** 2 - a)

# Example run
# Input:
-1
-3439167
# Output:
3439168
def ABC_74_A():
    N = int(input())
    A = int(input())
    print(N*N-A)

if __name__ == '__main__':

    ABC_74_A()

# Example run
# Input:
3
5
# Output:
4
N = int(input())
A = int(input())
print(N*N-A)

# Example run
# Input:
16707581
-16198
# Output:
279143262887759
n = int(input())
a = int(input())
 
print(n**2 - a)

# Example run
# Input:
-887384
13499019
# Output:
787436864437
n=int(input())
a=int(input())
print(n**-a)

# Example run
# Input:
-7311554
0
# Output:
1
n = int(input())
a = int(input())
print(n * n - a)

# Example run
# Input:
4331
-1463
# Output:
18759024
N=int(input())
A=int(input())
print(N**2-A)

# Example run
# Input:
-1504387
31
# Output:
2263180245738
n=int(input())
a=int(input())
print(n**2-a)

# Example run
# Input:
224
-3753932
# Output:
3804108
n = int(input())
a = int(input())
print(n**2 - a)

# Example run
# Input:
-1595467139
3280
# Output:
2545515391628842041
n = int(input())
a = int(input())
print(n**2 - a)

# Example run
# Input:
-91260894
16769
# Output:
8328550773662467
n = int(input())
a = int(input())

print(n*n-a)

# Example run
# Input:
2147483647
58
# Output:
4611686014132420551
def get_num():
    n = int(input())
    w = int(input())
    return n,w

def check_range(n,w):
    return n in range(1,101) and w in range(n**2)

def black_tiles(n,w):
    if (check_range(n,w)):
        return n**2 - w
    else:
        raise Exception('Value out of range')

if (__name__=='__main__'):
    print(black_tiles(*get_num()))
    

# Example run
# Input:
23
493
# Output:
36
n = int(input())
a = int(input())
print((n*n)-a)

# Example run
# Input:
0
-31
# Output:
31
n = int(input())
a = int(input())
print(n ** 2 - a)

# Example run
# Input:
0
-27
# Output:
27
N = int(input())
A = int(input())
print(N*N-A)

# Example run
# Input:
-19
-13
# Output:
374
def main():
    grid = int(input()) ** 2
    white_cell = int(input())
    print(grid - white_cell)


if __name__ == '__main__':
    main()



# Example run
# Input:
5228
-2059433
# Output:
29391417
N = int(input())
A = int(input())
print(N * N - A)

# Example run
# Input:
-80
19
# Output:
6381
n = int(input())
print(n**2-int(input()))


# Example run
# Input:
125090213
380581
# Output:
15647561388004788
n = int(input())
a = int(input())
print(n**2-a)

# Example run
# Input:
20735611
18
# Output:
429965563543303
N = int( input())
A = int( input())
print(N**2-A)

# Example run
# Input:
1115599
-206075
# Output:
1244561334876
N = int(input())
A = int(input())
print(N*2-A)

# Example run
# Input:
-108
624906
# Output:
-625122
n = int(input())
a = int(input())
print(n**2-a)

# Example run
# Input:
-24
-202024
# Output:
202600
total = int(input()) ** 2
white = int(input())
print(total - white)


# Example run
# Input:
20616
-11392175
# Output:
436411631
N=int(input())
A=int(input())

print(N**2-A)

# Example run
# Input:
0
15473
# Output:
-15473
N = int(input())
A = int(input())

answer = (N * N) - A

print(answer)

# Example run
# Input:
-256478906
-8056
# Output:
65781429222964892
N = int(input())
A = int(input())

print(N**2-A)

# Example run
# Input:
655579180
-22914821
# Output:
429784061272387221
n = int(input())
a = int(input())
print(n*n-a)

# Example run
# Input:
2
-8135
# Output:
8139
n=int(input())
a=int(input())
print(n*n-a)

# Example run
# Input:
1747702
0
# Output:
3054462280804
N = int(input())                                                                                                                                            
A = int(input())
  
ans = (N * N) - A
  
print(str(ans))

# Example run
# Input:
-28028
-640183291
# Output:
1425752075
N = int(input())
A = int(input())

print(N**2 - A)


# Example run
# Input:
0
16
# Output:
-16
#ALC005 A

N = int(input())
A = int(input())

print((N**2) - A)

# Example run
# Input:
27379
-32928895
# Output:
782538536
n = int(input())
a = int(input())
print(n*n - a)

# Example run
# Input:
14508349
-252699780
# Output:
210492443405581
N=int(input())
A=int(input())
print(N**2-A)

# Example run
# Input:
-614194311
-1
# Output:
377234651664764722
N = int(input())

sum = 0
flag = 0


a = int(N / 7)
re = N % 7

if re == 0:
    print('Yes')
    flag += 1
else:
    for i in range(a+1):
        sum = 7 * i
#        print(sum)
        while sum<N:
            sum += 4
#            print(sum)
            if sum == N:
                print('Yse')
                flag += 1
        if flag == 1:
            break

if flag == 0:
    print('No')
                


# Example run
# Input:
112781417
# Output:
Yes
N = int(input())
A = int(input())

print(N*N - A)


# Example run
# Input:
-23
38379
# Output:
-37850
a=int(input())
b=int(input())
print(a*a-b)

# Example run
# Input:
-1140169349
11327
# Output:
1299986144399072474
N = int(input())
A = int(input())

print(N ** 2 - A)


# Example run
# Input:
-6498
-4074336
# Output:
46298340
n=int(input())
a=int(input())
print(n*n-a)

# Example run
# Input:
11586
1726243
# Output:
132509153
n = int(input())
a = int(input())

print(n **2 - a)

# Example run
# Input:
2144
-155785153
# Output:
160381889
n = int(input())
a = int(input())
N = n*n
res = N -a
print(res)

# Example run
# Input:
-7
-242313086
# Output:
242313135
N = int(input())
A = int(input())
print(N*N-A)

# Example run
# Input:
-1325982
57961
# Output:
1758228206363
N = int(input())
A = int(input())
print(N**2 - A)

# Example run
# Input:
-104
14707
# Output:
-3891
def actual(N, A):
    return N ** 2 - A

N = int(input())
A = int(input())
print(actual(N, A))

# Example run
# Input:
65211
-69919
# Output:
4252544440
N = int(input())
A = int(input())
print(N**2-A)

# Example run
# Input:
-23420607
0
# Output:
548524832248449
N = int(input())
A = int(input())

print(N*N-A)

# Example run
# Input:
85673587
52
# Output:
7339963509446517
n=int(input())
a=int(input())
print(n*n-a)


# Example run
# Input:
83957
-1984507492
# Output:
9033285341
n = int(input())
a = int(input())

print(abs(n**2-a))


# Example run
# Input:
4159
9088477
# Output:
8208804
N = int(input())

A = int(input())

print(N**2-A)

# Example run
# Input:
-7581
25265073
# Output:
32206488
N = int(input())
A = int(input())
ans = N ** 2 - A
print(ans)

# Example run
# Input:
1
13370
# Output:
-13369
N = int(input())
A = int(input())
print(N**2-A)

# Example run
# Input:
-868
2583
# Output:
750841
n = int(input())
a = int(input())
print(n**2-a)

# Example run
# Input:
6
-224852
# Output:
224888
N=int(input())
A=int(input())

print(N*N-A)

# Example run
# Input:
949995462
51
# Output:
902491377820593393
n = int(input())
a = int(input())

menseki = n**2
print(int(menseki-a))

# Example run
# Input:
204095531
1
# Output:
41654985774171960
n = int(input())
a = int(input())
print( n*n - a)

# Example run
# Input:
-20720
-1
# Output:
429318401
N = int(input())
A = int(input())

print(N**2-A)


# Example run
# Input:
715035410
0
# Output:
511275637553868100
# coding: utf-8
# Here your code !
N=int(input().rstrip())
A=int(input().rstrip())
print((N**2)-A,flush=True)


# Example run
# Input:
-5310
-16
# Output:
28196116
# Nのますめと白に塗ったマス目Aを整数で入力
N = int(input())
A = int(input())
# N*NマスからAマス塗ったを余りを出力
print(N**2 - A)

# Example run
# Input:
21390345
1506
# Output:
457546859217519
n=int(input())
a=int(input())
print(n*n-a)

# Example run
# Input:
-989028
54353
# Output:
978176330431
n = int(input())
a = int(input())
print(n**2-a)

# Example run
# Input:
3032627
6744926
# Output:
9196819776203
n = int(input())
a = int(input())
print((n**2) - a)

# Example run
# Input:
3
10
# Output:
-1
#!/usr/bin/env python
# coding: utf-8


def main():
    n = int(input())
    a = int(input())
    print(n*n-a)

if __name__ == '__main__':
    main()


# Example run
# Input:
31934639
0
# Output:
1019821168060321
# -*- coding: utf-8 -*-


def main():
    """Function."""
    n = int(input())
    a = int(input())
    print(n*n - a)


if __name__ == "__main__":
    main()


# Example run
# Input:
-4283
169119120
# Output:
-150775031
#074_A
n=int(input())
a=int(input())
print(n*n-a)

# Example run
# Input:
-260
-1628416575
# Output:
1628484175
N = int(input())
A = int(input())

print(N**2-A)

# Example run
# Input:
0
-1049645
# Output:
1049645
n=int(input())
a=int(input())
print(n**2-a)

# Example run
# Input:
1250
-22914821
# Output:
24477321
n = int(input())
a = int(input())
print(n*n -a)

# Example run
# Input:
1686
-1719929315
# Output:
1722771911
n=int(input())
print(n*n-int(input()))


# Example run
# Input:
-36925
-15751
# Output:
1363471376
n = int(input())
a = int(input())
print(n**2 - a)

# Example run
# Input:
20735611
18
# Output:
429965563543303
# coding: utf-8
N = int(input())
A = int(input())
print((N * N) - A)

# Example run
# Input:
-129636061
-16
# Output:
16805508311595737
n = int(input())
a = int(input())
print(n*n-a)


# Example run
# Input:
-227170451
13499019
# Output:
51606413794044382
n=int(input())
a=int(input())
print(n*n-a)


# Example run
# Input:
470711
-1325982
# Output:
221570171503
N = int(input())
A = int(input())
print(N**2-A)

# Example run
# Input:
5184928
131358094
# Output:
26883347007090
N=int(input())
A=int(input())
print(N*N-A)

# Example run
# Input:
-7517
134
# Output:
56505155
n = int(input())
a = int(input())
print(n**2 - a)

# Example run
# Input:
-449705
-318594
# Output:
202234905619
#!/usr/bin/env pypy3
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))

def main():
    mod=10**9+7
    N=I()
    A=I()
    print(N*N-A)

main()


# Example run
# Input:
981571
-6163826
# Output:
963487791867
n=int(input())
a=int(input())
print(n**2-a)

# Example run
# Input:
-41270
-2
# Output:
1703212902
N=int(input())
A=int(input())
print(str(N**2-A))

# Example run
# Input:
20735611
18
# Output:
429965563543303
n = int(input())
a = int(input())

print(n*n-a)

# Example run
# Input:
2
120424111
# Output:
-120424107
a=int(input())
b=int(input())
print(a**2-b)

# Example run
# Input:
1686
-1719929315
# Output:
1722771911
n = int(input())
a = int(input())
print(n*n-a)

# Example run
# Input:
4475
-562
# Output:
20026187
N = int(input())
A = int(input())
print(N*N - A)

# Example run
# Input:
1
-68037
# Output:
68038
n=int(input())
a=int(input())
print(n**2-a)


# Example run
# Input:
456
212
# Output:
207724
n =int(input())
a =int(input())
print(n**2-a)

# Example run
# Input:
-28
-2
# Output:
786
n = int(input())
a = int(input())
print((n ** 2) - a)

# Example run
# Input:
2301222
3
# Output:
5295622693281
N = int(input())
A = int(input())
print(N*N - A)

# Example run
# Input:
-1024939794
-933046410
# Output:
1050501582257808846
N=int(input())
A=int(input())
print(N*N-A)

# Example run
# Input:
-3662
757115353
# Output:
-743705109
def resolve():
	n = int(input())
	a = int(input())
	print(n**2 - a)
resolve()

# Example run
# Input:
55
-45
# Output:
3070
n = int(input())
a = int(input())
print(n * n - a)

# Example run
# Input:
-1
-2147483648
# Output:
2147483649
a=int(input())
b=int(input())
print(int((a*a)-b))

# Example run
# Input:
-1
-491947
# Output:
491948
n=int(input())
a=int(input())
print(max(n**2-a, 0))

# Example run
# Input:
-39547
-46095437
# Output:
1610060646
n = int(input())
b = int(input())
print(n * n - b)

# Example run
# Input:
-75
57223618
# Output:
-57217993
N=int(input())
A=int(input())
print(N*N-A)

# Example run
# Input:
112734
211
# Output:
12708954545
n=int(input())
a=int(input())
print(n*n-a)

# Example run
# Input:
3
-31591
# Output:
31600
N=int(input())
A=int(input())
print (N*N-A)

# Example run
# Input:
3
-563
# Output:
572
n = int(input())
a = int(input())

print(n*n-a)


# Example run
# Input:
3320259
-2147483648
# Output:
11026267310729
n = int(input())
a = int(input())
print(n**2-a)

# Example run
# Input:
2144
-155785153
# Output:
160381889
N = int(input())
A = int(input())
 
print(N*N-A)

# Example run
# Input:
11609
-29082932
# Output:
163851813
n=int(input())
a=int(input())
print(n^2-a)

# Example run
# Input:
-57065
-189
# Output:
-56920
n = int(input())
a = int(input())
print(n**2 -a)

# Example run
# Input:
930196227
-6990
# Output:
865265020725042519
n = int(input())
a = int(input())

print(n*n -a)

# Example run
# Input:
378444
5
# Output:
143219861131
n=int(input())
a=int(input())
print(n*n - a)

# Example run
# Input:
-23
11980
# Output:
-11451
n = int(input())
a = int(input())
print(n*n -a)

# Example run
# Input:
115625
-15913
# Output:
13369156538
n=int(input())
a=int(input())
print(int(n**2.0 - a))

# Example run
# Input:
-12
242208
# Output:
-242064
n=int(input())
a=int(input())

print(n**2-a)

# Example run
# Input:
228552
-24756136
# Output:
52260772840
n=int(input())
a=int(input())
print(n*n-a)

# Example run
# Input:
-7698469
-5952
# Output:
59266424949913
N=int(input())
A=int(input())
print(N*N-A)

# Example run
# Input:
0
331737
# Output:
-331737
N = int(input())
A = int(input())

print(N ** 2 - A)

# Example run
# Input:
-172829
-227062494
# Output:
30096925735
a = int(input())
b = int(input())
print(a * a - b)


# Example run
# Input:
1965
587245588
# Output:
-583384363
a = int(input())
b = int(input())
print(a**2-b)

# Example run
# Input:
-125464087
14138
# Output:
15741237126729431
n = int(input())
a = int(input())
print(n * n - a)

# Example run
# Input:
533947427
15753484
# Output:
285099854784166845
n=int(input())
a=int(input())
print(n*n-a)

# Example run
# Input:
6637763
-9
# Output:
44059897644178
N = int(input())
A = int(input())
print(N ** 2 -A)

# Example run
# Input:
-1759593
-6
# Output:
3096167525655
n = int(input())
a = int(input())
print(n**2-a)

# Example run
# Input:
-161
20
# Output:
25901
n=int(input())
a=int(input())
x=n**2
print(x-a)

# Example run
# Input:
1307
-23
# Output:
1708272
N = int(input())
A = int(input())
print(N ** 2 - A)

# Example run
# Input:
-192707
237144
# Output:
37135750705
a = int(input())
b = int(input())

print(a**2-b)

# Example run
# Input:
-6940
6118
# Output:
48157482
def main():
    n = int(input())
    a = int(input())
    print(n * n - a)


if __name__ == '__main__':
    main()


# Example run
# Input:
-6325
1
# Output:
40005624
n = int(input())
a = int(input())

print((n*n)-a)

# Example run
# Input:
965909841
-6391502
# Output:
932981820947036783
square = int(input())
black = int(input())
white = (square * square) - black
print(white)


# Example run
# Input:
-187248
874391687
# Output:
34187421817
n = int(input())
a = int(input())
print(n * n - a)


# Example run
# Input:
-1198338
0
# Output:
1436013962244
N = int(input())
A = int(input())
print(N*N-A)

# Example run
# Input:
21
42
# Output:
399
N = int(input())
A = int(input())

print(-A+N**2)

# Example run
# Input:
254789424
-69433494
# Output:
64917650651685270