TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W = map(int, input().split())
h, w = map(int, input().split())
print(h * W + w* H - h * w)

H,W = map(int, input().split())
h, w = map(int, input().split())
print(H * W -(h * W + w* H - h * w))

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
a,b=map(int,input())
c,d=map(int,input())
print((a-c)*(b-d))

a,b=map(int,input().split())
c,d=map(int,input().split())
print((a-c)*(b-d))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
input_1 = input().split()

input_2 = input().split()

print((int(input_1[0]) - int(input_2[0])) * (int(input_1[1]) * int(input_2[1])))


input_1 = input().split()
h_l = int(input_1[0])
w_l = int(input_1[1])

input_2 = input().split()
h = int(input_2[0])
w = int(input_2[1])

result = (h_l - h) * (w_l * w)

print(result)


input_1 = input().split()

h_l = int(input_1[0])
w_l = int(input_1[1])

input_2 = input().split()

h = int(input_2[0])
w = int(input_2[1])

result = h_l * w_l - (h_l * w  + w_l * h) + w * h

print(result)


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W=map(int,input().split())
h,w=map(int,input().split())
print(h*W+H*w-h*w)

H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-h*W-H*w+h*w)


Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
a = [list(map(int, input().split())) for i in range(2)]
a[0][0] = H
a[0][1] = W
a[1][0] = h
a[1][1] = w
my_result = H * W - h * W - H * w + h * w
print(my_result)

a = [list(map(int, input().split())) for i in range(2)]
H = a[0][0] 
W = a[0][1] 
h = a[1][0] 
w = a[1][1] 
my_result = H * W - h * W - H * w + h * w
print(my_result)

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W = map(int,input().split())
h,w = map(int,input().split())

print(H*W-H*w-h*W-h*w)

H,W = map(int,input().split())
h,w = map(int,input().split())
 
print(H*W-H*w-h*W+h*w)

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
a,b = map(int,input.split())
c,d=map(int,input.split())
print((c-a)*(d-b))

a,b = map(int,input().split())
c,d=map(int,input().split())
print((c-a)*(d-b))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map( int, input().split() )
print( (H-1) * (W-1) )

H, W = map( int, input().split() )
h, w = map( int, input().split() )
print( (H-h) * (W-w) )

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-H*h-W*w+h*w)

H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-H*w-W*h+h*w)

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
ap(int,input().split())

H,W = map(int,input().split())
h,w = map(int,input().split())

print((H-h)*(W-w))


Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
3 2
2 1

H,W=list(map(int,input().split()))
h,w=list(map(int,input().split()))
print(H*W-h*W-w*H+h*w)

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
(H-h) * (W-w)

H, W = map(int, input().split())
h, w = map(int, input().split())
print((H-h)*(W-w))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input().split())
h, w = map(int, input().split())

white_cells_int = H * W - ((h * W) + (w * H) - (h * w)
print(white_cells_int)


n, m, c = map(int,input().split())
B = list(map(int,input().split()))
A = [input().split() for l in range(n)]
cnt = 0
for i in range(n):
    sum = 0
    for j in range(m):
        sum += int(A[i][j]) * B[j]
    if sum + c > 0:
        cnt += 1
print(cnt)


H, W = map(int, input().split())
h, w = map(int, input().split())

white_cells_int = H * W - ((h * W) + (w * H) - (h * w))
print(str(white_cells_int))


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input().split())
h, w = map(int, input().split())
print(H*W - h*w)

H, W = map(int, input().split())
h, w = map(int, input().split())
print((H-h) * (W-w))

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
import numpy as np

N, M = map(int, input().split())
A = []
B = []

for i in range(0, N):
    a, b = np.array(list(map(float, input().split())))
    A.append(a)
    B.append(b)

cnt = 0
sum = 0
flag = 0
inf = float('inf')
arrayA = np.array(A)
arrayB = np.array(B)
for j in range(0, N):
    idx = A.index(min(arrayA))
    pay = arrayA[idx]
    num = arrayB[idx]
    arrayA[idx]=inf
    if cnt + num < M :
        cnt += num
        sum += pay*num
    else :
        diff = int(M - cnt)
        for t in range(0, diff):
            sum += pay
            cnt += 1
            if cnt == M :
                flag = 1
                print(int(sum))
                break
    if flag == 1:
        break


H, W = map(int, input().split())
h, w = map(int, input().split())
all = H * W
print(all - (h*W + w * H - h*w))


Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
n,m = map(int,input().split(' '))
cost = 0
count = 0

mlist = list()
for i in range(n):
  mlist.append(list(map(int,input().split(' '))))
mlist.sort(key=lambda x: x[0])

for i in range(n):
  ablist = mlist[i]
  if count+ablist[1] <= m:
    count += ablist[1]
    cost += ablist[0]*ablist[1] 
  else:
    for j in range(ablist[1]):
      count += 1
      if count <= m:
        cost += ablist[0]
      else:
        break_t = True
        break
    if break_t:
      break
print(cost)



hh, ww = map(int,input().split(' '))
h, w = map(int,input().split(' '))
ans = (hh-h)*(ww-w)
print(ans)

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
A,B = input().split()
a,b = input().split()
print(A*B-a*B-b*A+a*b)

A,B = input().split()
a,b = input().split()
A = int(A)
B = int(B)
a = int(a)
b = int(b)
print(A*B-a*B-b*A+a*b)

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W=map(int,input().split())
hi,wi=map(int,input().split())

print(W*hi+H*wi-hi*wi)

H,W=map(int,input().split())
hi,wi=map(int,input().split())

print(W*H-W*hi-H*wi+hi*wi)

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input().split())
h, w = map(int, input().split())
print(H * W - (h * w))


H, W = map(int, input().split())
h, w = map(int, input().split())
print((H - h) * (W - w))

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
h,w=map(int,input().split())
_1,_2=map(int,input().split())
print((h-1)*(w-1))

h,w=map(int,input().split())
h0,w0=map(int,input().split())
print((h-h0)*(w-w0))

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
A, B = map(int,input().split())

pre = A
for i in range(A+1,B+1):
    pre  = pre ^ i
print(pre)

H, W = map(int,input().split())
h, w = map(int,input().split())
ans = (H-h) * (W-w)
print(ans)

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input(),split())
h, w = map(int, input(),split())
print((H-h)*(W-w))


H, W = map(int, input().split())
h, w = map(int, input().split())
print((H-h)*(W-w))


Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):

def to_bin(n):
  s = ''
  while n > 0:
    s += str(n%2)
    n //= 2
  return s[::-1]

def xor(s1, s2):
  s1 = '0'*(len(s2)-len(s1)) + s1
  result = ''
  for i in range(len(s1)):
    if s1[i] == s2[i]:
      result += '0'
    else:
      result += '1'
  return result

def to_den(s):
  s = s[::-1]
  total = 0
  for i in range(0, len(s)):
    total += 2**i*int(s[i])
  return total

def main():
  A, B = map(int, input().split())
  if A == B:
    print(A)
    exit(1)

  cur = xor(to_bin(A), to_bin(A+1))

  for i in range(A+2, B+1):
    s = to_bin(i)
    cur = xor(cur, s)

  print(to_den(cur))

main()



def to_bin(n):
  s = ''
  while n > 0:
    s += str(n%2)
    n //= 2
  return s[::-1]

def xor(s1, s2):
  s1 = '0'*(len(s2)-len(s1)) + s1
  result = ''
  for i in range(len(s1)):
    if s1[i] == s2[i]:
      result += '0'
    else:
      result += '1'
  return result

def to_den(s):
  s = s[::-1]
  total = 0
  for i in range(0, len(s)):
    total += 2**i*int(s[i])
  return total

A, B = map(int, input().split())
if A == B:
  print(A)
else:
  cur = xor(to_bin(A), to_bin(A+1))

  for i in range(A+2, B+1):
    s = to_bin(i)
    cur = xor(cur, s)

  print(to_den(cur))




def to_bin(n):
  s = ''
  while n > 0:
    s += str(n%2)
    n //= 2
  return s[::-1]

def xor(s1, s2):
  s1 = '0'*(len(s2)-len(s1)) + s1
  result = ''
  for i in range(len(s1)):
    if s1[i] == s2[i]:
      result += '0'
    else:
      result += '1'
  return result

def to_den(s):
  s = s[::-1]
  total = 0
  for i in range(0, len(s)):
    total += 2**i*int(s[i])
  return total

def main():
  A, B = map(int, input().split())
  if A == B:
    print(A)
  else:
    cur = xor(to_bin(A), to_bin(A+1))

    for i in range(A+2, B+1):
      s = to_bin(i)
      cur = xor(cur, s)

    print(to_den(cur))

main()


H, W = map(int, input().split())
h,w = map(int, input().split())

print(abs(H-h)*abs(W-w))

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input())
h, w = map(int, input())

print((H-h) * (H-h))


H, W = map(int, input())
h, w = map(int, input())

print((W-w) * (H-h))


H, W = map(int, input().split())
h, w = map(int, input().split())

print((W-w) * (H-h))

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
p,q= input().split()
a,b =(int(p), int(q))
P,Q= input().split()
A,B =(int(P), int(Q))
print(int(a*b - A*B))

p,q= input().split()
a,b =(int(p), int(q))
P,Q= input().split()
A,B =(int(P), int(Q))
print(int((a-A)*(b-B)))

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
def get_ints():
  return map(int, input().split())

N, _, C = get_ints()
B = list(get_ints())

n = 0
for _ in range(N):
  A = list(get_ints())
  J = sum(a * b for a, b in zip(A, B)) + C
  if J > 0:
  	n += 1
    
print(n)


H, W = map(int, input().split())
h, w = map(int, input().split())

print((H - h) * (W - w))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
from collections import defaultdict, deque
import sys

INF = float('inf')
def LI(): return list(map(int, sys.stdin.buffer.readline().split()))
def I(): return int(sys.stdin.buffer.readline())
def LS(): return sys.stdin.buffer.readline().rstrip().decode('utf-8').split()
def S(): return sys.stdin.buffer.readline().rstrip().decode('utf-8')
def IR(n): return [I() for i in range(n)]
def LIR(n): return [LI() for i in range(n)]
def SR(n): return [S() for i in range(n)]
def LSR(n): return [LS() for i in range(n)]
def SRL(n): return [list(S()) for i in range(n)]
def MSRL(n): return [[int(j) for j in list(S())] for i in range(n)]


h1, w1 = LI()
h, w = LI()
ans = max(0, h * w)
print(ans)


from collections import defaultdict, deque
import sys

INF = float('inf')
def LI(): return list(map(int, sys.stdin.buffer.readline().split()))
def I(): return int(sys.stdin.buffer.readline())
def LS(): return sys.stdin.buffer.readline().rstrip().decode('utf-8').split()
def S(): return sys.stdin.buffer.readline().rstrip().decode('utf-8')
def IR(n): return [I() for i in range(n)]
def LIR(n): return [LI() for i in range(n)]
def SR(n): return [S() for i in range(n)]
def LSR(n): return [LS() for i in range(n)]
def SRL(n): return [list(S()) for i in range(n)]
def MSRL(n): return [[int(j) for j in list(S())] for i in range(n)]


h1, w1 = LI()
h, w = LI()
ans = max(0, (h1 - h) * (w1 - w))
print(ans)


Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W = map(int,input().split())
h,w = map(int,input().split())

print((H*W + h*w) - (H*w + Wh))

H,W = map(int,input().split())
h,w = map(int,input().split())

print((H*W + h*w) - (H*w + W*h))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(list, input().split())
h, w = map(list, input().split())

print((H-h)*(W-w))


H, W = map(int, input().split())
h, w = map(int, input().split())

print((H-h)*(W-w))


Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
a,b=input().split()
c,d=input().split()
print((a-c)*(b-d))

a,b=input().split()
c,d=input().split()
a=int(a)
b=int(b)
c=int(c)
d=int(d)
print((a-c)*(b-d))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
3 2
2 1

H, W = map(int, input().strip().split())
h, w = map(int, input().strip().split())

res = (H - h) * (W - w)
print(res)


Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W = map(int,input())
r,c = map(int,input())

import numpy as np

matrix = np.ones((H,W),dtype="uint8")
matrix[0:r,:] = 0
matrix[:,0:c] = 0
print(matrix.sum())


H,W = map(int,input().split())
r,c = map(int,input().split())

import numpy as np

matrix = np.ones((H,W),dtype="uint8")
matrix[0:r,:] = 0
matrix[:,0:c] = 0
print(matrix.sum())


Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W = map(int,input().split)
h,w = map(int,input().split)
print((H*W)-(h*w))

List = [list(map(int,input().split())) for i in range(2)]
print((List[0][0]-List[1][0])*(List[0][1]*List[1][1]))

H,W = map(int,input().split())
h,w = map(int,input().split())
print((H*W)-(h*w))

List = [list(map(int,input().split())) for i in range(2)]
print((List[0][0]*List[0][1])-(List[1][0]*List[1][1]))

H,W = map(int,input().split())
h,w = map(int,input().split())
print((H-h)*(W-w))

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-h*W-w*h+h*w)

H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-h*W-w*H+h*w)


Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
N, M, C = map(int, input().split())
B = [int(_) for _ in input().split()]
for i in range(1, N + 1):
    Ai = [int(_) for _ in input().split()]
right = 0
for i in range(1,N + 1):
    for j in range(M):
        a = 0
        a += Ai[j] * B[j]
    if a + C > 0:
        right += 1
print(right)

H, W = map(int, input().split())
h, w = map(int, input().split())
ans = H * W - h * W - w * H + h * w
print(ans)

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W=map(int,input().split())
h,w=map(int,input().split())
ka=h*w
print(H*W-ka)

H,W=map(int,input().split())
h,w=map(int,input().split())
ka=h*w
print(H*W-h*W-w*H+ka)

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
n, m, c = map(int, input().split())
b_list = list(map(int, input().split()))
count = 0

for _ in range(n):
    a_list = list(map(int, input().split()))
    sum = c

    for i in range(m):
        sum += a_list[i] * b_list[i]

    if sum > 0:
        count += 1

print(count)


H, W = map(int, input().split())
h, w = map(int, input().split())
print((H - h) * (W - w))


Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W=input().split()
h,w=input().split()
print((H-h)*(W-w))

H,W=map(int,input().split())
h,w=map(int,input().split())
print((H-h)*(W-w))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-h-w+1)

H,W=map(int,input().split())
h,w=map(int,input().split())
print(H+W-h-w+1)

H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-h*W-w*H+w*h)

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input.split())
h, w = map(int, input.split())

print((H-h)*(W-w))

a = [input() for i in range(2)]
H, W = map(int, a[0].split())
h, w = map(int, a[1].split())
print((H-h)*(W-w))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
#A - White Cells

import numpy as np

H, W = map(int, input().split())
h, w = map(int, input().split())

Orig = np.ones((H, W))
Orig[0:h, :] =0
Orig[:, 0:w ] =0

total = np.sum(Orig)
print(total)

#A - White Cells

import numpy as np

H, W = map(int, input().split())
h, w = map(int, input().split())

Orig = np.ones((H, W))
Orig[0:h, :] =0
Orig[:, 0:w ] =0

total = int(np.sum(Orig))
print(total)

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
a=list(int(input(),split()))
b=list(int(input(),split()))

s=(a[0]-b[0])*(a[1]-b[1])
print(s)

a=list(int(input().split()))
b=list(int(input().split()))
print(a[0]-b[0])*(a[1]-b[1])

a=list(int(input().split()))
b=list(int(input().split()))

s=(a[0]-b[0])*(a[0]-b[0])
print(s)

a=list(map(int,input().split()))
b=list(map(int,input().split()))
print((a[0]-b[0])*(a[1]-b[1]))

Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
# input
H, W = map(int, input().split())
h, w = map(int, input().split())


print(H * W - ((H * h) + (W * w) - (h * w)))

# input
H, W = map(int, input().split())
h, w = map(int, input().split())


if (H, W) == (h, w):
    print(0)
else:
    print(H * W - ((H * h) + (W * w) - (h * w)))

# input
H, W = map(int, input().split())
h, w = map(int, input().split())


if (H, W) == (h, w):
    print(0)
else:
    print(H * W - ((W * h) + (H * w) - (h * w)))

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
hh, ww = map(int, input(),split())
h, w = map(int, input(),split())
s = hh*ww - h*ww - hh*w + hh*ww
print(s)

hh, ww = map(int, input(),split())
h, w = map(int, input(),split())

print(hh*ww - h - w + 1)

hh,ww = map(int, input().split())
h, w = map(int, input().split())
s = hh*ww - h*ww - hh*w + hh*ww
print(s)

hh,ww = map(int, input().split())
h, w = map(int, input().split())
s = hh*ww - h*ww - hh*w + h*w
print(s)

Verdicts: Runtime Error

Runtime Error

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W = map(int,input().split())
h,w = map(int,input().split())
print((h-H)*(W-w))
          
          

H,W = map(int,input().split())
h,w = map(int,input().split())
print((H-h)*(W-w))


Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
# -*- Coding: utf-8 -*-

import numpy as np

INPUT=input().split( )
Input=input().split( )
H=int(INPUT[0])
W=int(INPUT[1])
h=int(Input[0])
w=int(Input[1])

mat=np.ones((H,W))
mat[0:h,:]=0
mat[:,0:w]=0

print(mat.sum())

# -*- Coding: utf-8 -*-

import numpy as np

INPUT=input().split()
Input=input().split()
H=int(INPUT[0])
W=int(INPUT[1])
h=int(Input[0])
w=int(Input[1])

mat=np.ones((H,W))
mat[0:h,:]=0
mat[:,0:w]=0

print(np.sum(mat))

# -*- Coding: utf-8 -*-

import numpy as np

H,W=int(input().split())
h,w=int(input().split())

mat=np.ones((H,W))
mat[0:h,:]=0
mat[:,0:w]=0

print(np.sum(mat))

# -*- Coding: utf-8 -*-

import numpy as np

INPUT=input().split()
Input=input().split()
H,W=int(INPUT[0]),int(INPUT[1])
h,w=int(Input[0]),int(Input[1])

mat=np.ones((H,W))
mat[0:h,:]=0
mat[:,0:w]=0

print(np.sum(mat))

import numpy as np

H,W=input().split()
h,w=input().split()

mat=np.ones((H,W))
mat[0:h,:]=0
mat[:,0:w]=0

print(np.sum(mat))

# -*- Coding: utf-8 -*-

import numpy as np

INPUT=input().split()
Input=input().split()
H,W=int(INPUT[0]),int(INPUT[1])
h,w=int(Input[0]),int(Input[1])

mat=np.ones((H,W))
mat[0:h,:]=0
mat[:,0:w]=0

print(int(np.sum(mat)))

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Wrong Answer

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input())
h, w = map(int, input())
print((H-h)*(W-w))

H, W = map(int, input().split())
h, w = map(int, input().split())
print((H-h)*(W-w))


Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W = map(int, input().split())
h,w = map(int, input().split())

print(H*W-h-w+1)

h,w = map(int,input().split())
a,b = map(int,input().split())
print(h*w - a * w - b * h + a * b)

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W = map(int,input().split())
h,w = map(int,input().split())
print(h*W + w*H -h*w)

H,W = map(int,input().split())
h,w = map(int,input().split())
print(H*W - (h*W + w*H -h*w))

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W,h,w=[map(int, input().split()) for _ in range(2)]
print((H-h)*(W-w))

a,b=[map(int, input().split()) for _ in range(2)]
print((a[0]-b[0])*(a[1]-b[1]))


H,W=map(int,input().split())
h,w=map(int,input().split())
print((H-h)*(W-w))


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input.split())
h, w = map(int, input.split())
print((H-h)*(W-w))

H, W = map(int, input().split())
h, w = map(int, input().split())
print((H-h)*(W-w))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input().split())
h, w = map(int, input().split())
ans = H * W - h * H - w * W + h * w
print(ans)

H, W = map(int, input().split())
h, w = map(int, input().split())
ans = H * W - h * W - w * H + h * w
print(ans)

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-h*H-w*W+h*w)

H,W=map(int,input().split())
h,w=map(int,input().split())
print((H-h)*(W-w))

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
n, k = map(int, input().split())
s = input()

print(s[:k-1] + s[k-1].lower() + s[k:n])

H, W = map(int, input().split())
h, w = map(int, input().split())

print((H - h) * (W - w))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input().split())
h, w = map(int, input().split())
print(H*W - h*w)

H, W = map(int, input().split())
h, w = map(int, input().split())
print(H*W - (h*W + w*H))

H, W = map(int, input().split())
h, w = map(int, input().split())
print(H * W - (h * W + w * H) + h * w)


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-(W*h)+((H*w)-(h*w)))

H,W=int(input())
h,w=int(input())
print(H*W-(W*h)+((H*w)-(h*w)))

H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-((W*h)+((H*w)-(h*w))))

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
a,b = map(int,input().split())
c,d = map(int,input().split())
print(a*b-c*d-d*c+c*d)

a,b = map(int,input().split())
c,d = map(int,input().split())
print(a*b-c-d+c*d)

a,b = map(int,input().split())
c,d = map(int,input().split())
print(a*b-c-d+1)

a,b = map(int,input().split())
c,d = map(int,input().split())
print(a*b-c-d+cd)

a,b = map(int,input().split())
c,d = map(int,input().split())
print(a*b-c*b-d*a+c*d)

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W,h,w=map(int,open(0));print((H-h)*(W-w))

H,W,h,w=map(int,open(0).read().split());print((H-h)*(W-w))

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = [int(_) for _ in input().split()]
h, w = [int(_) for _ in input().split()]
print(H*W-h*w)

H, W = [int(_) for _ in input().split()]
h, w = [int(_) for _ in input().split()]
print((H-h)*(W-w))


Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H,W = list(map(int,input().split()))
h,w = list(map(int,input().split()))
print(H,W,h,w)
ans = h*W + w*H - h*w
print(H*W-ans)

H,W = list(map(int,input().split()))
h,w = list(map(int,input().split()))
#print(H,W,h,w)
ans = h*W + w*H - h*w
print(H*W-ans)

Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
K,w = [int(x) for x in input().split()]
h,w = [int(x) for x in input().split()]
print (K*W -(K-h)*(W-w))

K,W = [int(x) for x in input().split()]
h,w = [int(x) for x in input().split()]
print (K*W -(K-h)*(W-w))

K,W = [int(x) for x in input().split()]
h,w = [int(x) for x in input().split()]
print (K*W -(K-w)*(W-h))

K,W = [int(x) for x in input().split()]
h,w = [int(x) for x in input().split()]
print (K*W -(K-h)*(W-w))

K,W = [int(x) for x in input().split()]
h,w = [int(x) for x in input().split()]
print ((K-h)*(W-w))

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H, W = map(int, input().split())
h, w = map(int, input().split())

print((H * W) - (h * H + w * W - h * w)

H, W = map(int, input().split())
h, w = map(int, input().split())

print((H * W) - (h * H + w * W - h * w))

H, W = map(int, input().split())
h, w = map(int, input().split())

print((H * W) - (h * W + w * H - h * w))

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
a, b = map(int, input().split())
c, d = map(int, input().split())
if (a*b)==(c*d):
 print((a*b)-(c*d))
else if (a*b) > (c*d):
 print(c*d)

a, b = map(int, input().split())
c, d = map(int, input().split())
if (a*b)==(c*d):
 print((a*b)-(c*d))
else if (a*b) > (c*d):
 print((c*d))

a, b = map(int, input().split())
c, d = map(int, input().split())
if (a*b)==(c*d):
 print((a*b)-(c*d))
else if (a*b ) > (c*d):
  print((c*d))

a, b = map(int, input().split())
c, d = map(int, input().split())
[print("0") if (a*b)=(c*d) else print(c*d)]

a, b = map(int, input().split())
c, d = map(int, input().split())
if (a*b)==(c*d):
 print("0")
else if (a*b ) > (c*d):
  print(c*d)

a, b = map(int, input().split())
c, d = map(int, input().split())
[print("0") if (a*b)==(c*d) else print(c*d)]

a, b = map(int, input().split())
c, d = map(int, input().split())
if (a*b)==(c*d):
 print((a*b)-(c*d))
elseif (a*b ) > (c*d):
  print((c*d))

    a, b = map(int, input().split())
    c, d = map(int, input().split())
    if (a*b)==(c*d):
     print((a*b)-(c*d))
    elif (a*b) > (c*d):
     print(c*d)

a, b = map(int, input().split())
c, d = map(int, input().split())
print((a-c)*(b-d))

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
H = int(input())
W = int(input())
h = int(input())
w = int(input())
tate = H-h
yoko = W-w
print(tate*yoko)

H = int(input())
W = int(input())
h = int(input())
w = int(input())
print((H-h)*(W-w))

H = input()
W = input()
h = input()
w = input()
tate = H-h
yoko = W-w
print(tate*yoko)

import numpy as np
H,W = map(int, input().split())
h,w = map(int, input().split())
print((H-h)*(W-w))

Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
HW = list(map(int, input().split))
hw = list(map(int, input().split))

print(HW[0]*HW[1] - hw[0]*HW[1] - HW[0]*hw[1] + hw[0]*hw[1])

HW = list(map(int, input().split()))
hw = list(map(int, input().split()))
 
print(HW[0]*HW[1] - hw[0]*HW[1] - HW[0]*hw[1] + hw[0]*hw[1])

Verdicts: Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
h, w=map(int, input().split())
H, W=map(int, input().split())
print(H*W-h*w)

h, w, H, W=map(int, input().split())
print(h*W+w*H-w*h)

h, w=map(int, input().split())
H, W=map(int, input().split())
print((H-h)*(W*w))

h, w=map(int, input().split())
H, W=map(int, input().split())

print((H-h)*(W-w))

Verdicts: Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
a,b = map(int,input().split())

h,w = map(int,input().split())

print(a*b-h*w)


a,b = map(int,input().split())

h,w = map(int,input().split())

print((a-h)*(b-w))


Verdicts: Wrong Answer

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
n,m=map(int,input().split())
lst=[list(map(int,input().split()))]
for i in range(n-1):
    a=list(map(int,input().split()))
    x=0
    for j in range(len(lst)):
        if x > m :break
        if lst[j][0] > a[0]:
            lst.insert(j,a)
            break
        x+=lst[j][1]
        
ans=0
num=0
for i in lst:
    if i[1]+num>=m:
        ans+=i[0]*(m-num)
        break
    ans+=i[0]*i[1]
    num+=i[1]
print(ans)

n,m=map(int,input().split())
lst=[list(map(int,input().split()))]
for i in range(n-1):
    a=list(map(int,input().split()))
    x=0
    for j in range(len(lst)):
        if x > m :break
        if lst[j][0] > a[0]:
            lst.insert(j,a)
            break
        x+=lst[j][1]
        
ans=0
num=0
for i in lst:
    if i[1]+num>=m:
        ans+=i[0]*(m-num)
        break
    ans+=i[0]*i[1]
    num+=i[1]
print(ans,lst)

H,W=map(int,input().split())
h,w=map(int,input().split())
print(H*W-H*w-h*W+h*w)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: There are H rows and W columns of white square cells.  You will choose h of the rows and w of the columns, and paint all of the cells contained in those rows or columns.  How many white cells will remain?  It can be proved that this count does not depend on what rows and columns are chosen.

Submission attempts (in order):
a,b=map(int,input().split())
c,d=map(int,input().split())
print(int(((a-c)*(b-d)))

a,b=map(int,input().split())
c,d=map(int,input().split())
print(int((a-c)*(b-d)))


Verdicts: Runtime Error

Accepted