s_id stringlengths 10 10 | p_id stringlengths 6 6 | u_id stringlengths 10 10 | date stringlengths 10 10 | language stringclasses 1
value | original_language stringclasses 11
values | filename_ext stringclasses 1
value | status stringclasses 1
value | cpu_time stringlengths 1 5 | memory stringlengths 1 7 | code_size stringlengths 1 6 | code stringlengths 1 539k |
|---|---|---|---|---|---|---|---|---|---|---|---|
s623913745 | p03997 | u449555432 | 1550948110 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 47 | a,b,h=map(int,input().split());print((a+b)*h/2) |
s330008740 | p03997 | u777028980 | 1550095774 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 54 | a,b,h=map(int,input().split())
print(int((a+b)*h/2))
|
s627929949 | p03997 | u777028980 | 1550095724 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 48 | a,b,h=map(int,input().split())
print((a+b)*h/2)
|
s419167022 | p03997 | u777028980 | 1550095701 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 47 | a,b,c=map(int,input().split())
print((a+b)*h/2) |
s944882816 | p03997 | u500297289 | 1549791836 | Python | Python (3.4.3) | py | Runtime Error | 18 | 2940 | 77 | """ AtCoder """
a, b, h = map(int, input().split())
print((a + b) * h / 2)
|
s432628990 | p03997 | u690536347 | 1548781886 | Python | PyPy3 (2.4.0) | py | Runtime Error | 172 | 38384 | 48 | a,b,h=map(int,input().split())
print((a+b)*h//2) |
s551188171 | p03997 | u079644963 | 1546910970 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 344 | a = input()
ar = []
for i in range(3):
ar.append(a[i])
n = len(ar)
ret = 0
for i in range(n+1):
s = "+"
tmp = ""
for j in range(n):
if (1 & (i >> j)) == 1:
tmp += ar[j]
tmp += s
else:
tmp += ar[j]
stmp = tmp.split("+")
ret += sum(int(k) for k in stmp)
print(int(ret)) |
s346576470 | p03997 | u785578220 | 1546211518 | Python | Python (3.4.3) | py | Runtime Error | 18 | 2940 | 67 | a = int(input())
b = int(input())
c = int(input())
print((a+b)*h/2) |
s585050556 | p03997 | u740284863 | 1546084664 | Python | Python (3.4.3) | py | Runtime Error | 20 | 3060 | 62 | a=int(input())
b=int(input())
c=int(input())
print((a+b)*h/2)
|
s601793387 | p03997 | u740284863 | 1546084632 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 63 | a=int(input())
b=int(input())
c=int(input())
print((a+b)*h//2)
|
s440090262 | p03997 | u726439578 | 1546062853 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 54 | a=int(input)
b=int(input)
c=int(input)
print(a*b*c//2) |
s609581239 | p03997 | u726439578 | 1546062732 | Python | Python (3.4.3) | py | Runtime Error | 18 | 2940 | 54 | a=int(input)
b=int(input)
c=int(input)
print(a*b*h//2) |
s461392100 | p03997 | u643840641 | 1546009456 | Python | Python (3.4.3) | py | Runtime Error | 18 | 2940 | 52 | a, b, h = map(int, input().split())
print((a+b)*h/2) |
s323098907 | p03997 | u726439578 | 1545975964 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 55 | a=int(input)
b=int(input)
c=int(input)
print(a*b*h///2) |
s275833854 | p03997 | u272377260 | 1544892735 | Python | Python (3.4.3) | py | Runtime Error | 18 | 2940 | 63 | a, b, h = map(int, input().split())
print(int((a + b) * h / 2)) |
s990957490 | p03997 | u272377260 | 1544892624 | Python | Python (3.4.3) | py | Runtime Error | 20 | 2940 | 63 | a, b, h = map(int, input().split())
print(int((a + b) * h / 2)) |
s075734264 | p03997 | u272377260 | 1544892556 | Python | Python (3.4.3) | py | Runtime Error | 18 | 2940 | 58 | a, b, h = map(int, input().split())
print((a + b) * h / 2) |
s470386597 | p03997 | u272377260 | 1544892504 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3188 | 63 | a, b, h = map(int, input().split())
print(int((a + b) * h / 2)) |
s859869301 | p03997 | u920299620 | 1543334540 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 49 | a,b,h=map(int,input().split())
print( (a+b)*h/2 ) |
s775347155 | p03997 | u759360502 | 1541889234 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 72 | a = int(input())
b = int(input())
h = int(input())
print(int((a+b)/2*h) |
s492528796 | p03997 | u637824361 | 1540852880 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 57 | a, b, h = map(int, input().split())
print((a+b) * (h/2))
|
s307907785 | p03997 | u848647227 | 1539792629 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 70 | a = list(map(int,input().split(" ")))
print((a[0] + a[1]) * a[2] // 2) |
s721344946 | p03997 | u320325426 | 1538860858 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 66 | a, b, h = [int(input()) for i in range(4)]
print((a + b) * h // 2) |
s202152174 | p03997 | u337802798 | 1538703009 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 68 | a = int(input())
b = int(input())
c = int(input())
print((a+b)*h//2) |
s122222901 | p03997 | u608088992 | 1537982107 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 68 | A = int(input())
B = int(input())
H = int(input())
print((A+b)*H//2) |
s032380673 | p03997 | u214617707 | 1533998629 | Python | Python (3.4.3) | py | Runtime Error | 16 | 2940 | 76 | a = int(input())
b = int(input())
c = int(input())
print(((a + b) * h) // 2) |
s741827117 | p03997 | u879870653 | 1533659978 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 64 | a,b,h=map(int,input().split())
ans=(a+b)*h*0.5
print(int(ans))
|
s918752639 | p03997 | u879870653 | 1533659931 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 59 | a,b,h=map(int,input().split())
ans=(a+b)*h*0.5
print(ans)
|
s816328755 | p03997 | u146382803 | 1533322384 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 68 | a = list(map(int,input().split()))
print((a[0] + a[1]) * a[2] // 2)
|
s768508180 | p03997 | u146382803 | 1533321959 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3060 | 57 | a,b,h = map(int,input().split())
print((a + b) * h // 2)
|
s363230865 | p03997 | u146382803 | 1533321680 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 90 | import math
a,b,h = map(int,input().split())
ans = math.floor((a + b) * h / 2)
print(ans)
|
s093812294 | p03997 | u434500430 | 1533057041 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 53 | a, b, h = map(int, input().split())
print((a+b)*h//2) |
s296652592 | p03997 | u434500430 | 1533056862 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 52 | a, b, h = map(int, input().split())
print((a+b)*h/2) |
s983042785 | p03997 | u957239743 | 1532802068 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 899 | #include<iostream>
#include<float.h>
#include<cfloat>
#include<string>
#include<ctype.h>
#include<algorithm>
#include<errno.h>
#include<cerrno>
#include<assert.h>
#include<cassert>
#include<map>
#include<memory.h>
#include<cctype>
#include<ctype.h>
#include<math.h>
#include<vector>
#include<cstdio>
#include<set>
#include<string.h>
#include<stdio.h>
#include<new>
#include<memory>
#include<cmath>
#include<queue>
#include<cstring>
#define ll long long
#define fo(i,m,n) for(int i=(int)m;i<(int)n;i++)
#define br break
#define ct continue
#define pb push_back
#define pi 3.141592653589793238462643383279502884197169
#define F first
#define S second
#define pii pair<int,int>
#define em empty()
#define vei vector<int>
#define ves vector<string>
#define qui queue<int>
#define qu queue
using namespace std;
int main()
{int a,b,c;
cin>>a>>b>>c;
cout<<(a+b)*c/2;
system("pause");
return 0;
} |
s814819055 | p03997 | u052347048 | 1532657482 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 89 | upperbase,bottom,high = map(int,input().split())
print((upperbase + bottom) * high / 2) |
s873491647 | p03997 | u052347048 | 1532657450 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3188 | 89 | upperbase,bottom,high = map(int,input().split())
print((upperbase + bottom) * high / 2) |
s098402587 | p03997 | u052347048 | 1532657373 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 88 | upperbase,bottom,high = map(int,input().split())
print((upperbase + bottom) * high // 2) |
s399264065 | p03997 | u409064224 | 1529189358 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 56 | a,b,h = list(map(int,input().split()))
print((a+b)*h/2) |
s074138720 | p03997 | u724892495 | 1529110273 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 49 | print((int(input())+int(input())*int(input())//2) |
s353768907 | p03997 | u724892495 | 1529110202 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 47 | print((int(input()+int(input())*int(input()//2) |
s521805835 | p03997 | u351426847 | 1525111396 | Python | Python (2.7.6) | py | Runtime Error | 10 | 2568 | 115 | if __name__ == '__main__':
a = raw_input()
b = raw_input()
h = raw_input()
print ((a + b) * h / 2)
|
s998271581 | p03997 | u145035045 | 1523991613 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 56 | print( (int(input()) + int(input()) * int(input()) // 2) |
s031264356 | p03997 | u391475811 | 1522119420 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 91 | a=int(input().split())
b=int(input().split())
c=int(input().split())
print(int((a+b)*c/2)) |
s517808105 | p03997 | u632369368 | 1520752491 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 150 | SA = list(input())
SB = list(input())
SC = list(input())
D = {'a': SA, 'b': SB, 'c': SC}
now = 'a'
while D[now]:
now = D[now].pop()
print(now)
|
s857536966 | p03997 | u355798276 | 1513258601 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 76 | a = int(input())
b = int(input())
h = int(input())
print((a + b) * h / 2))
|
s361901746 | p03997 | u214380782 | 1500159683 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 70 | a, b, h = map(int, input().split())
S = (a + b) * h / 2
print(int(S)) |
s479631554 | p03997 | u214380782 | 1500159469 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 139 | numsstr = input().split()
nums = []
for i in range(3):
nums.append(int(numsstr[i]))
S = (nums[0] + nums[1]) * nums[2] / 2
print(int(S)) |
s832621084 | p03997 | u616040357 | 1496115363 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 115 | def solve():
a, b, c = map(int, input().split())
print((a + b)*c/2)
if __name__ == '__main__':
solve() |
s903221184 | p03997 | u340250862 | 1486344716 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 72 | lis = [int(input()) for i in range 3]
print(int(lis[0]*lis[1]*lis[2]/2)) |
s184198212 | p03997 | u045337404 | 1479513838 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 91 | a = raw_input('')
b = raw_input('')
h = raw_input('')
print((int(a) + int(b)) * int(h) /2)
|
s047680449 | p03997 | u045337404 | 1479513540 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 97 | a = raw_input('')
b = raw_input('')
h = raw_input('')
x = (int(a) + int(b)) * int(h) /2
print(x)
|
s429869777 | p03997 | u359930418 | 1479473590 | Python | PyPy3 (2.4.0) | py | Runtime Error | 204 | 38896 | 232 | Python 3.5.2 (v3.5.2:4def2a2901a5, Jun 25 2016, 22:01:18) [MSC v.1900 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> a = 3
>>> b = 6
>>> h = 8
>>> print((a + b) * h / 2 )
36.0
>>> |
s095401889 | p03997 | u089636269 | 1478582468 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 74 | a = int(input())
b = int(input())
h = int(input())
print(int((a+b)*h //2) |
s822885024 | p03997 | u089636269 | 1478582392 | Python | Python (3.4.3) | py | Runtime Error | 22 | 3064 | 86 | a, b, h = list(map(int, str.split("\n")))
S = (int(a) + int(b)) * int(h) // 2
print(S) |
s075490147 | p03997 | u089636269 | 1478582023 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 102 | # coding: UTF8
a, b, h = list(map(int, int(input()).split("\n")))
S = int((a + b) * h // 2)
print(S) |
s706604121 | p03997 | u089636269 | 1478582022 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 102 | # coding: UTF8
a, b, h = list(map(int, int(input()).split("\n")))
S = int((a + b) * h // 2)
print(S) |
s638140004 | p03997 | u089636269 | 1478581922 | Python | Python (3.4.3) | py | Runtime Error | 24 | 3064 | 101 | # coding: UTF8
a, b, h = int(list(map(int, input().split("\n"))))
S = int((a + b) * h // 2)
print(S) |
s949251946 | p03997 | u089636269 | 1478581848 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 97 | # coding: UTF8
a, b, h = list(map(int, input().split("\n")))
S = int((a + b) * h // 2)
print(S) |
s793934419 | p03997 | u089636269 | 1478581613 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 151 | # coding: UTF8
N = 3
# N = int(input())
str = [input() for i in range(N)]
# print str
a = str[0]
b = str[1]
h = str[2]
S = (a + b) * h // 2
print(S)
|
s542270802 | p03997 | u089636269 | 1478581411 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 126 | N = int(input())
str = [input() for i in range(N)]
# print str
a = str[0]
b = str[1]
h = str[2]
S = (a + b) * h // 2
print(S) |
s202372892 | p03997 | u089636269 | 1478581166 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 121 | N = input()
str = [input() for i in range(N)]
# print str
a = str[0]
b = str[1]
h = str[2]
S = (a + b) * h // 2
print(S) |
s353829258 | p03997 | u089636269 | 1478581093 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 75 | a, b, h = list(map(int, input().split("\n")))
S = (a + b) * h // 2
print(S) |
s337667639 | p03997 | u089636269 | 1478498818 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 75 | a, b, h = list(map(int, input().split("\n")))
S = (a + b) * h / 2
print(S) |
s554897161 | p03997 | u089636269 | 1478498535 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 118 | N = input()
str = [input() for i in range(N)]
print str
a = str[0]
b = str[1]
h = str[2]
S = (a + b) * h / 2
print(S) |
s093097827 | p03997 | u089636269 | 1478498397 | Python | Python (3.4.3) | py | Runtime Error | 24 | 3064 | 74 | a, b, h = list(map(int, input().split("\n")))
S = (a + b) * h / 2
print(S) |
s400977419 | p03997 | u580920947 | 1477360251 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 143 | # -*- coding: utf-8 -*-
N = 3
# N = int(input())
s = [input() for i in range(N)]
a = s[1]
b = s[2]
h = s[3]
S = ((a + b)*h/2)
print(str(S))
|
s872909399 | p03997 | u580920947 | 1477360074 | Python | Python (3.4.3) | py | Runtime Error | 24 | 3064 | 138 | # -*- coding: utf-8 -*-
N = 3
# N = int(input())
s = [input() for range(N)]
a = s[1]
b = s[2]
h = s[3]
S = ((a + b)*h/2)
print(str(S)) |
s162520859 | p03997 | u448407332 | 1476759901 | Python | Python (2.7.6) | py | Runtime Error | 17 | 2568 | 62 | a, b, h = map(int, raw_input().split())
print (a + b) * h / 2
|
s847982066 | p03997 | u541921833 | 1476567902 | Python | Python (2.7.6) | py | Runtime Error | 16 | 2568 | 489 | a = str(raw_input())
b = str(raw_input())
c = str(raw_input())
if len(a) == 1:
print 'a'
return
s = a[0]
a = a[1:]
while True:
if s == 'a':
if len(a) == 1:
print 'a'
break
s = a[0]
a = a[1:]
elif s == 'b':
if len(b) == 1:
print 'b'
break
s = b[0]
b = b[1:]
elif s == 'c':
if len(c) == 1:
print 'c'
break
s = c[0]
c = c[1:]
|
s452504541 | p03997 | u541921833 | 1476565808 | Python | Python (2.7.6) | py | Runtime Error | 15 | 2568 | 113 | a = int(raw_input())
b = int(raw_input())
h = int(raw_input())
print "{}".format(int((a+b)*h/2))
|
s097462633 | p03997 | u610143410 | 1476130093 | Python | Python (3.4.3) | py | Runtime Error | 24 | 3444 | 1446 | class board:
def __init__(self, h, w):
self.h = h
self.w = w
self.pieces = self.make_pieces()
self.results = dict()
def make_pieces(self):
pieces = []
for i in range(self.h):
for j in range(self.w):
pieces.append(0)
return pieces
def draw(self, i, j):
i -= 1; j-= 1
index = j + i * self.w
print(index)
self.pieces[index] = 1
def start_scan(self):
for i in range(self.w - 2):
print(i)
for j in range(self.h - 2):
print(j)
num = 0
for x in range(i, i+3):
for y in range(j, j+3):
index = x + y * self.w
v = self.pieces[index]
print("v = {0}".format(v))
if v == 1:
num += 1
self.results[num] = num
def searched_box(self, num):
return self.results.get(num, 0)
if __name__ == '__main__':
args = input().split(' ')
board_h = int(args[0])
board_w = int(args[1])
n = int(args[2])
board = board(board_h, board_w)
for _ in range(n):
args = input().split(' ')
i = int(args[0])
j = int(args[1])
board.draw(i, j)
board.start_scan()
for i in range(10):
print(board.searched_box(i))
|
s638107623 | p03997 | u731028462 | 1475902476 | Python | Python (3.4.3) | py | Runtime Error | 24 | 3064 | 52 | a = input()
b = input()
h = input()
print((a+b)*h/2) |
s179390557 | p03997 | u776189585 | 1475613488 | Python | Python (2.7.6) | py | Runtime Error | 17 | 2692 | 78 | a = int(raw_input())
b = int(raw_input())
c = int(raw_input())
print (a+b)*h/2 |
s926432446 | p03997 | u226155577 | 1475450205 | Python | Python (3.4.3) | py | Runtime Error | 24 | 3064 | 80 | S={c:list(input())for c in"abc"}
s="a"
while S[s]:s=S[s].pop(0)
print(s.upper()) |
s653006324 | p03997 | u276144769 | 1474738588 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3068 | 186 | s={}
for i in range(3):
s[chr(97+i)]=input()
turn="a"
while True:
if not s[turn]:
break
else:
turn=s[turn][0]
s[turn]=s[turn][1:]
print(turn.upper())
|
s217068717 | p03997 | u276144769 | 1474738364 | Python | Python (3.4.3) | py | Runtime Error | 22 | 3064 | 186 | s={}
for i in range(3):
s[chr(97+i)]=input()
turn="a"
while True:
if not s[turn]:
break
else:
turn=s[turn][0]
s[turn]=s[turn][1:]
print(turn.upper())
|
s393362188 | p03997 | u102438343 | 1474722283 | Python | Python (2.7.6) | py | Runtime Error | 16 | 2568 | 87 | a = int(raw_input())
b = int(raw_input())
h = int(raw_input())
return ((a + b) / 2) * h |
s735053546 | p03997 | u862517767 | 1473821107 | Python | PyPy3 (2.4.0) | py | Runtime Error | 371 | 42992 | 405 | h,w,n=map(int,input().split())
d={}
for _ in range(n):
a,b=map(int,input().split())
for i in (-1,0,1):
for j in (-1,0,1):
if 2<=a+i<=h-1 and 2<=b+j<=w-1:
d.setdefault((a+i,b+j),0)
d[a+i,b+j]+=1
r=[0]*10
for i in d.values():
r[i]+=1
r[0]=(h-2)*(w-2)-sum(r)
for i in r:
print(i) |
s334965755 | p03997 | u464852639 | 1473803683 | Python | Python (3.4.3) | py | Runtime Error | 40 | 3064 | 63 | a = int(input)
b = int(input)
h = int(input)
print((a+b)*(h/2)) |
s641670390 | p03997 | u830390742 | 1473789377 | Python | Python (2.7.6) | py | Runtime Error | 28 | 2568 | 610 | H, W, N = map(int, raw_input().split())
dx = [-1, 0, 1, -1, 0, 1, -1, 0, 1]
dy = [-1, -1, -1, 0, 0, 0, 1, 1, 1]
board = {}
for i in xrange(N):
a, b = map(int, raw_input().split())
for j in xrange(9):
x, y = a+dx[j], b+dy[j]
if x <= 1 or x >= H or y <= 1 or y >= W:
continue
if (x, y) in board:
board[(x, y)] += 1
else:
board[(x, y)] = 1
ans = [0] * 10
for v in board.values():
ans[v] += 1
ans[0] = (H-2)*(W-2)-sum(ans)
for a in ans:
print a |
s170374716 | p03997 | u284188208 | 1473787290 | Python | Python (2.7.6) | py | Runtime Error | 28 | 2568 | 67 | a = input()
b = input()
h = input()
print (a+b)*h/2 |
s365839144 | p03997 | u555199741 | 1473729013 | Python | Python (2.7.6) | py | Runtime Error | 26 | 2568 | 61 | a, b, h = map(int, raw_input().split())
print (a + b) * h / 2 |
s328635979 | p03997 | u361243145 | 1473707187 | Python | Python (2.7.6) | py | Runtime Error | 28 | 2820 | 600 | class nSnukes_Coloring:
def returnEachNumber(self,H,W,N,r):
HWMap = [[0 for i in range(W+2)] for j in range(H+2)]
points = [0 for i in range(10)]
for cord in range(len(r)):
y,x = r[cord][0],r[cord][1]
for i in range(3):
for j in range(3):
HWMap[y-i+1][x-j+1] += 1
for i in range(H-2):
for j in range(W-2):
points[HWMap[i+2][j+2]] += 1
for i in range(len(points)):
print points[i]
if __name__ == "__main__":
H, W, N = map(int, raw_input().split())
r = [[int(i) for i in raw_input().split()] for i in range(N)]
s = nSnukes_Coloring()
s.returnEachNumber(H,W,N,r) |
s589737052 | p03997 | u361243145 | 1473707062 | Python | Python (2.7.6) | py | Runtime Error | 29 | 2696 | 600 | class nSnukes_Coloring:
def returnEachNumber(self,H,W,N,r):
HWMap = [[0 for i in range(W+2)] for j in range(H+2)]
points = [0 for i in range(10)]
for cord in range(len(r)):
y,x = r[cord][0],r[cord][1]
for i in range(3):
for j in range(3):
HWMap[y-i+1][x-j+1] += 1
for i in range(H-2):
for j in range(W-2):
points[HWMap[i+2][j+2]] += 1
for i in range(len(points)):
print points[i]
if __name__ == "__main__":
H, W, N = map(int, raw_input().split())
r = [[int(i) for i in raw_input().split()] for i in range(N)]
s = nSnukes_Coloring()
s.returnEachNumber(H,W,N,r) |
s037334070 | p03997 | u010075034 | 1473654288 | Python | Python (3.4.3) | py | Runtime Error | 38 | 3064 | 238 | if __name__ == '__main__':
players = {}
players['a'] = list(input())
players['b'] = list(input())
players['c'] = list(input())
t = 'a'
while len(players[t]) > 0:
t = players[t].pop(0)
print(t.upper())
|
s616007841 | p03997 | u309333806 | 1473648525 | Python | PyPy3 (2.4.0) | py | Runtime Error | 360 | 43376 | 555 | from collections import defaultdict
def inside(x, y):
return 0 <= x <= h - 3 and 0 <= y <= w - 3
h, w, n = (int(_) for _ in input().split())
black = defaultdict(int)
for i in range(n):
a, b = (int(_) - 1 for _ in input().split())
for j in range(3):
for k in range(3):
x, y = a - j, b - k
if not inside(x, y):
continue
black[(x, y)] += 1
ans = [0 for i in range(10)]
ans[0] = (h-2)*(w-2) - len(black)
for k in black:
ans[black[k]] += 1
for i in range(10):
print(ans[i])
|
s871994012 | p03997 | u699994820 | 1473644460 | Python | Python (3.4.3) | py | Runtime Error | 37 | 3064 | 87 | a = int(input())
b, c = map(int, input().split())
result = int(a*(b+c)/2)
print(result) |
s503953936 | p03997 | u699994820 | 1473644151 | Python | Python (3.4.3) | py | Runtime Error | 38 | 3064 | 66 | a = int(input())
b, c = map(int, input().split())
print(a*(b+c)/2) |
s055854582 | p03997 | u587295817 | 1473643364 | Python | Python (3.4.3) | py | Runtime Error | 40 | 3064 | 46 | a=input()
b=input()
h=input()
print((a+b)*h/2) |
s715958262 | p03997 | u678875535 | 1473643288 | Python | Python (3.4.3) | py | Runtime Error | 38 | 3064 | 88 | a=input().split()
b=input().split()
h=input().split()
ans=((a + b) * h) / 2
print(ans) |
s296226670 | p03997 | u969062340 | 1473642728 | Python | Python (2.7.6) | py | Runtime Error | 26 | 2568 | 149 | def solve(a, b, h):
return (a + b) * h / 2
a = raw_input()
int(a)
b = raw_input()
int(b)
h = raw_input()
int(h)
ans = solve(a, b, h)
print ans
|
s996537589 | p03997 | u969062340 | 1473642653 | Python | Python (2.7.6) | py | Runtime Error | 28 | 2572 | 216 | import sys
def solve(a, b, h):
return (a + b) * h / 2
a = sys.stdin.readline().rstrip()
int(a)
b = sys.stdin.readline().rstrip()
int(b)
h = sys.stdin.readline().rstrip()
int(h)
ans = solve(a, b, h)
print ans
|
s179287059 | p03997 | u969062340 | 1473642528 | Python | Python (2.7.6) | py | Runtime Error | 31 | 2568 | 229 | import sys
def solve(a, b, h):
return (a + b) * h / 2
a = sys.stdin.readline().rstrip()
int(a)
b = sys.stdin.readline().rstrip()
int(b)
h = sys.stdin.readline().rstrip()
int(h)
ans = solve(a, b, h)
print "{0}".format(ans) |
s738145157 | p03997 | u969062340 | 1473642426 | Python | Python (2.7.6) | py | Runtime Error | 27 | 2572 | 248 | # encoding: utf-8
import sys
def solve(a, b, h):
return (a + b) * h / 2
a = sys.stdin.readline().rstrip()
int(a)
b = sys.stdin.readline().rstrip()
int(b)
h = sys.stdin.readline().rstrip()
int(h)
ans = solve(a, b, h)
print "{0}".format(ans)
|
s640505281 | p03997 | u969062340 | 1473642401 | Python | Python (2.7.6) | py | Runtime Error | 27 | 2568 | 331 | # encoding: utf-8
import sys
def solve(a, b, h):
return (a + b) * h / 2
def main():
a = sys.stdin.readline().rstrip()
int(a)
b = sys.stdin.readline().rstrip()
int(b)
h = sys.stdin.readline().rstrip()
int(h)
ans = solve(a, b, h)
print "{0}".format(ans)
if __name__ == "__main__":
main()
|
s533556229 | p03997 | u969062340 | 1473642308 | Python | Python (2.7.6) | py | Runtime Error | 25 | 2568 | 306 | # encoding: utf-8
import sys
def solve(a, b, h):
return (a + b) * h / 2
def main():
a = sys.stdin.readline().rstrip()
int(a)
b = sys.stdin.readline().rstrip()
int(b)
h = sys.stdin.readline().rstrip()
int(h)
print solve(a, b, h)
if __name__ == "__main__":
main()
|
s610837209 | p03997 | u969062340 | 1473642204 | Python | Python (2.7.6) | py | Runtime Error | 27 | 2572 | 307 | # encoding: utf-8
import sys
def solve(a, b, h):
return (a + b) * h / 2.
def main():
a = sys.stdin.readline().rstrip()
int(a)
b = sys.stdin.readline().rstrip()
int(b)
h = sys.stdin.readline().rstrip()
int(h)
print solve(a, b, h)
if __name__ == "__main__":
main()
|
s018593806 | p03997 | u969062340 | 1473642142 | Python | Python (2.7.6) | py | Runtime Error | 25 | 2568 | 307 | # encoding: utf-8
import sys
def solve(a, b, h):
return (a + b) / h / 2.
def main():
a = sys.stdin.readline().rstrip()
int(a)
b = sys.stdin.readline().rstrip()
int(b)
h = sys.stdin.readline().rstrip()
int(h)
print solve(a, b, h)
if __name__ == "__main__":
main()
|
s077978144 | p03997 | u712335892 | 1473642129 | Python | Python (3.4.3) | py | Runtime Error | 39 | 3064 | 71 | a = input()
b = input()
h = input()
ret = ((a + b ) * h) / 2
print(ret) |
s456481755 | p03998 | u306412379 | 1600915236 | Python | Python (3.8.2) | py | Runtime Error | 27 | 9160 | 788 | s_a = input()
s_b = input()
s_c = input()
turn = str()
isCalledOnce = True
turn = s_a[0]
s_a = s_a.lstrip(turn)
while len(s_a) >= 1 and len(s_b) >= 1 and len(s_c) >= 1:
if turn == "a" and isCalledOnce:
s_a = s_a.lstrip(s_a[0])
if len(s_a) == 0:
break
turn = s_a[0]
isCalledOnce = False
if turn == "b" and isCalledOnce:
s_b = s_b.lstrip(s_b[0])
if len(s_b) == 0:
break
turn = s_b[0]
isCalledOnce = False
if turn == "c" and isCalledOnce:
s_c = s_c.lstrip(s_c[0])
if len(s_b) == 0:
break
turn = s_c[0]
isCalledOnce = False
isCalledOnce = True
if turn == "a":
print("A")
if turn == "b":
print("B")
if turn == "c":
print("C") |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.