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
s907420682
p02380
u216425054
1471443173
Python
Python3
py
Runtime Error
0
0
223
import math a,b,C=map(int,input().split()) C_rad=math.pi*C/180 S=(1/2)*a*b*math.sin(C_rad) L=a+b+math.sqrt(a**2+b**2-2*a*b*cos(C_rad)) h=2*S/a print("{0:.8f}".format(S)) print("{0:.8f}".format(L)) print("{0:.8f}".format(h))
s764809742
p02380
u998435601
1473605802
Python
Python3
py
Runtime Error
0
0
212
import math a,b,c = map(float, raw_input().split()) cc = math.radians(c) h = b * math.sin(cc) S = a * h / 2 L = a + b + math.sqrt(h**2 + (a-b*math.cos(cc))**2) print("{0:.5f}\n{1:.5f}\n{2:.5f}\n".format(S, L, h))
s156758712
p02380
u801346721
1478602303
Python
Python3
py
Runtime Error
0
0
242
import math a, b, C = map(float, input().split() C_rad = math.radians(C) c = math.sqrt(a**2 + b**2 - 2 * a * b * math.cos(C_rad)) S = a * b * math.sin(C_rad) / 2 L = a + b + c h = b * math.sin(C_rad) print("{0:.6} {1:.6} {2:.6}".format(S, L,
s625759131
p02380
u801346721
1478602333
Python
Python3
py
Runtime Error
0
0
245
import math a, b, C = map(float, input().split() C_rad = math.radians(C) c = math.sqrt(a**2 + b**2 - 2 * a * b * math.cos(C_rad)) S = a * b * math.sin(C_rad) / 2 L = a + b + c h = b * math.sin(C_rad) print("{0:.6} {1:.6} {2:.6}".format(S, L, h))
s307049155
p02380
u548155360
1487322297
Python
Python3
py
Runtime Error
0
0
199
import math a, b, C = map(int, input().split()) S = a * b * math.sin(C) * 0.5 c2 = a ** 2 + b ** 2 - 2 * a * b * math.cos(C) c = sqrt(c2) L = a + b + c h = 2 * S / a print(S) print(L) print(h)
s732775978
p02380
u301461168
1488246500
Python
Python3
py
Runtime Error
0
0
365
import math ?? len_a, len_b, deg_C = map(int,input().split(" ")) rad_C = math.radians(deg_C) ?? #area S = (1/2) * len_a * len_b * math.sin(rad_C) #Length L = len_a + len_b + math.sqrt(len_a ** 2 + len_b ** 2 + 1/2 * len_a * len_b * math.cos(rad_C)) #height h = len_b * math.sin(rad_C) ?? print("{:.5f}".format(S)) print("{:.5f}".format(L)) print("{:.5f}".format(h))
s131122865
p02380
u130834228
1489150526
Python
Python3
py
Runtime Error
0
0
197
#S, L, h import math a, b, C = map(int, input().split()) S = a*b*math.sin(C*math.pi/180)*(1/2) L = a+b+math.sqrt(a*a+b*b-2*a*b*math.cos(C*math.pi/180)) h = 2*S/a print('%.4f %.4f %.4f '% s, L, h)
s773055014
p02380
u426534722
1489235372
Python
Python3
py
Runtime Error
0
0
238
import math a, b, c = [float(i) for i in input().split()] cos(math.radians(c)) print(a * b * math.sin(math.radians(c)) / 2) print(a + b + math.sqrt(a**2 + b**2 - 2 * a * b * math.cos(math.radians(c)))) print(b * math.sin(math.radians(c)))
s809351421
p02380
u650790815
1496458604
Python
Python3
py
Runtime Error
0
0
171
import math a,b,t = map(int,input().split()) t = math.radians(t) h = b.math.sin(t) l = a + b + math.sqrt(a*a + b*b -2*a*b*math.cos(t)) s = h * a print(s) pritn(l) print(h)
s325468642
p02380
u650790815
1496636214
Python
Python3
py
Runtime Error
0
0
177
a,b,t = map(int,input()) import math h = b * math.cos(math.radians(t)) s = a*h l = a + b +math.sqrt(a**2 + b**2 -2*a*b*math.cos(math.radians(t))) print('{} {} {}'.format(s,l,h))
s162943922
p02380
u650790815
1496636393
Python
Python3
py
Runtime Error
0
0
192
a,b,t = map(int,input().split()) import math h = b*math.sin(radians(t)) s = a * h l = a + b +math.sqrt(a**2 + b**2 -2*a*b*math.cos(math.radians(t))) print('{0.8f} {1.8f} {2.8f}'.format(s,l,h))
s457154951
p02380
u650790815
1496636574
Python
Python3
py
Runtime Error
0
0
174
import math a,b,t = map(int,input().strip().split()) t = math.radians(t) h = b*sin(t) s = a * h /2 l = a + b + math.sqrt(a**2 + b**2 -2*a*b*cos(t)) print(s) print(l) print(h)
s612546684
p02380
u498511622
1501146174
Python
Python3
py
Runtime Error
0
0
205
import math a,b,C=map(int,input().split()) C2=math.radians(C) sin=math.sin(C2) cos=math.cos(C2) S = 0.5*a*b*sin L = a+b+(math.sqrt((a**2+b**2)-(2*a*b*cos))) H = (a*b*sin/2)(a/2) print(S) print(L) print(H)
s160033746
p02380
u498511622
1501146281
Python
Python3
py
Runtime Error
0
0
205
import math a,b,C=map(int,input().split()) C2=math.radians(C) sin=math.sin(C2) cos=math.cos(C2) S = 0.5*a*b*sin L = a+b+(math.sqrt((a**2+b**2)-(2*a*b*cos))) H = (a*b*sin/2)(a/2) print(S) print(L) print(H)
s455518293
p02380
u498511622
1501146415
Python
Python3
py
Runtime Error
0
0
259
import math a,b,C=map(int,input().split()) C2=math.radians(C) sin=math.sin(C2) cos=math.cos(C2) S = 0.5*a*b*sin L = a+b+(math.sqrt((a**2+b**2)-(2*a*b*cos))) H = (a*b*sin/2)(a/2) print("{0:.8f}".format(S)) print("{0:.8f}".format(L)) print("{0:.8f}".format(H))
s485259652
p02380
u853619096
1502194392
Python
Python3
py
Runtime Error
0
0
162
import numpy as np a,b,s=map(float,input().split()) s=np.radians(s) S=(a*b*np.sin(s))/2 h=b*np.sin(s) l=a+b+(a**2+b**2-2*a*b*np.cos(s)) print(S) print(l) print(h)
s699338928
p02380
u853619096
1502194948
Python
Python3
py
Runtime Error
0
0
167
import numpy as np a,b,s=map(float,input().split()) s=np.radians(s) S=(a*b*np.sin(s))/2 h=b*np.sin(s) l=a+b+(a**2+b**2-2*a*b*np.cos(s))**0.5 print(S) print(l) print(h)
s302959839
p02380
u853619096
1502354053
Python
Python3
py
Runtime Error
0
0
118
import math x1,y1,x2,y2=map(float,input().split()) x2=x2-x1 y2=y2-y1 x1,y1=0,0 dis=(x2**2+y2**2) print(math.sqrt(dis))
s964943699
p02380
u506705885
1505640229
Python
Python3
py
Runtime Error
0
0
182
import numpy as nu import math a,b,c=input().split() a=int(a) b=int(b) c=int(c) S=1/2*a*b*nu.sin(c) L=a+b+math.sqrt(a*a+b*b-2*a*b*nu.cos(c)) H=b*nu.sin(c) print(S) print(L) print(H)
s012432892
p02380
u506705885
1505641445
Python
Python3
py
Runtime Error
0
0
245
import math ?? a, b, C = input().split() a = float(a) b = float(b) C = float(C) ?? c = math.sqrt(((a*a) + (b*b) - 2*a*b*math.cos(math.radians(C)))) L = a + b + c S = a*b*math.sin(math.radians(C))/2 h = 2*S/a print("%.5f\n%.5f\n%.5f" % (S, L, h))
s855207708
p02380
u294922877
1518743159
Python
Python3
py
Runtime Error
0
0
513
import math def triangle(a, b, deg): result = {} rad = math.radians(deg) // 余弦定理 c = math.sqrt(a*a+b*b-(2*a*b*math.cos(rad))) s = (a+b+c)/2 result['area'] = math.sqrt(s*(s-a)*(s-b)*(s-c)) result['perimeter'] = a+b+c result['height'] = result['area'] * 2 / a return result if __name__ == '__main__': a, b, deg = map(int, input().split()) triangle = triangle(a, b, deg) print(triangle['area']) print(triangle['perimeter']) print(triangle['height'])
s492259028
p02380
u592529978
1526284569
Python
Python
py
Runtime Error
0
0
226
import math a,b,C = map(int, raw_input()) c = math.sqrt(a*a + b*b - 2*a*b*math.cos(math.radians(C))) S = (a * b * math.sin(math.radians(C))) / 2 L = a + b + c h = (S * 2) / a print("%f" % S) print("%f" % L) print("%f" % h)
s114573852
p02380
u592529978
1526291691
Python
Python
py
Runtime Error
0
0
239
import math a,b,C = map(int, raw_input()) c = math.sqrt(a*a + b*b - 2*a*b*math.cos(math.radians(C))) S = (a * b * math.sin(math.radians(C))) / 2 L = a + b + c h = (S * 2) / a print("%f" % (S, )) print("%f" % (L, )) print("%f" % (h, ))
s115539779
p02380
u592529978
1526291714
Python
Python
py
Runtime Error
0
0
238
import math a,b,C = map(int, raw_input()) c = math.sqrt(a*a + b*b - 2*a*b*math.cos(math.radians(C))) S = (a * b * math.sin(math.radians(C))) / 2 L = a + b + c h = (S * 2) / a print("%f" % (S, )) print("%f" % (L, )) print("%f" % (h, ))
s112386460
p02380
u592529978
1526345770
Python
Python
py
Runtime Error
0
0
218
import math a,b,C = map(int,raw_input()) c = math.sqrt(a*a+b*b-2*a*b*math.cos(math.radians(C))) L = a+b+c S = (a*b*math.sin(math.radians(C))) /2 h = (S*2)/a print("%f" % (S, )) print("%f" % (L, )) print("%f" % (h, ))
s583718131
p02380
u908651435
1526452018
Python
Python3
py
Runtime Error
0
0
169
import math a,b,c=map(int,input().split()) sinc=round(math.sin(math.radians(c))) s=1/2*a*b*sinc l=math.sqrt(a**2+b**2-2*a*b*cosc)+a+b h=s*2/a print(s) print(l) print(h)
s309008510
p02380
u986478725
1527350070
Python
Python3
py
Runtime Error
0
0
470
# AOJ ITP1_10_A import math def floatinput(): a = input().split() for i in range(len(a)): a[i] = float(a[i]) return a def main(): data = floatinput() a = data[0]; b = data[1]; C = data[2] S = a * b * 0.5 * math.cos(math.radians(C)) c = math.sqrt(a ** 2 + b ** 2 - 2 * a * b * math.cos(math.radians(C))) L = a + b + c h = b * math.sin(math.radians(C)) print(S); print(L): print(h) if __name__ == "__main__": main()
s763666190
p02380
u912237403
1371069295
Python
Python
py
Runtime Error
0
0
193
import sys import math for line in sys.stdin: if len(line)>1: a, b, c = line.strip('\n').split() a, b, c = int(a), int(b), int(c) print a * b * math.sin(radians(c))
s247101322
p02380
u633068244
1393335429
Python
Python
py
Runtime Error
0
0
140
import math a, b, c = map(float, raw_input()) print a*b*math.sin(c)/2 print a+b+math.sqrt(a**2+b**2-2*a*b*math.cos(c)) print b*math.sin(c)
s000350954
p02380
u633068244
1393335440
Python
Python
py
Runtime Error
0
0
140
import math a, b, c = map(float, raw_input()) print a*b*math.sin(c)/2 print a+b+math.sqrt(a**2+b**2-2*a*b*math.cos(c)) print b*math.sin(c)
s438627634
p02381
u281808376
1540516349
Python
Python3
py
Runtime Error
0
0
19
import numpy as np
s740371506
p02381
u281808376
1540516356
Python
Python3
py
Runtime Error
0
0
19
import Numpy as np
s255198538
p02381
u281808376
1540527046
Python
Python3
py
Runtime Error
0
0
308
from statistics import mean, median,variance,stdev data=[] while True: data.append(input().split()) if ["0"] in data: break data=data[:-1] data_i=[] for i in data: data_i.append(list(map(lambda i:int(i),i))) for i in data_i: if len(i)==1: pass else: print(std(i))
s312394129
p02381
u281808376
1540532681
Python
Python3
py
Runtime Error
0
0
20
import numpy as np
s849053830
p02381
u281808376
1540532844
Python
Python3
py
Runtime Error
0
0
337
from statistics import mean, median,variance,stdev data=[] while True: data.append(input().split()) if ["0"] in data: break data=data[:-1] data_i=[] def a(): for i in data: data_i.append(list(map(lambda i:int(i),i))) for i in data_i: if len(i)==1: pass else: print(statistics.pstdev(i))
s150418949
p02381
u281808376
1540532880
Python
Python3
py
Runtime Error
0
0
304
import statistics data=[] while True: data.append(input().split()) if ["0"] in data: break data=data[:-1] data_i=[] def a(): for i in data: data_i.append(list(map(lambda i:int(i),i))) for i in data_i: if len(i)==1: pass else: print(statistics.pstdev(i))
s681368529
p02381
u198574985
1545409887
Python
Python3
py
Runtime Error
0
0
357
while True: num = int(input()) if num == 0: break scores = input().split() for i in range(num): scores[i] = float(scores[i]) avr = sum(scores) / num daviation = 0 for a in scores: disp = (a - avr)**2/num daviation += disp p print(round(math.sqrt(daviation),8))
s943245911
p02381
u198574985
1545410078
Python
Python3
py
Runtime Error
0
0
372
open(0) while True: num = int(input()) if num == 0: break scores = input().split() for i in range(num): scores[i] = float(scores[i]) avr = sum(scores) / num daviation = 0 for a in scores: disp = (a - avr)**2/num daviation += disp p print(round(math.sqrt(daviation),8))
s907610000
p02381
u198574985
1545410155
Python
Python3
py
Runtime Error
0
0
383
f = open(0).read() while True: num = int(input()) if num == 0: break scores = input().split() for i in range(num): scores[i] = float(scores[i]) avr = sum(scores) / num daviation = 0 for a in scores: disp = (a - avr)**2/num daviation += disp p print(round(math.sqrt(daviation),8))
s827178107
p02381
u198574985
1545411423
Python
Python3
py
Runtime Error
0
0
449
daviations = [] while True: num = int(input()) if num == 0: break scores = input().split() for i in range(num): scores[i] = float(scores[i]) avr = sum(scores) / num daviation = 0 for a in scores: disp = (a - avr)**2/num daviation += disp daviations.append(round(math.sqrt(daviation),8)) for b in daviations: print(b)
s374923114
p02381
u083560765
1556274825
Python
Python3
py
Runtime Error
0
0
139
import statistics a=int(input()) while True: if a==0: break else: num=list(map(int,input().split())) print(statistics.pstdev(num))
s381825900
p02381
u083560765
1556274885
Python
Python3
py
Runtime Error
0
0
141
import statistics a=int(input()) while True: if a==0: break else: num=list(map(int,input().split())) print(statistics.pstdev(num))
s440429650
p02381
u025362139
1556849292
Python
Python3
py
Runtime Error
0
0
191
#coding: UTF-8 import statistics as st while True: N = int(input()) if N = 0: break buf = list(map(float, input().split())) sd = st.pstdev(buf) print("%.8f"%sd)
s651423531
p02381
u175224634
1556863207
Python
Python3
py
Runtime Error
0
0
213
from statistics import stdev while 1: num = int(input()) if num == 0: break else: data = list(map(int, input().split())) print(data) st = stdev(data) print(st)
s990096990
p02381
u535719732
1559309447
Python
Python3
py
Runtime Error
0
0
138
from statistics * while True: n = int(input()) if(n == 0): break data = list(map(int,input().split())) print(stdev(data))
s217114004
p02381
u535719732
1559309456
Python
Python3
py
Runtime Error
0
0
145
from statistics import * while True: n = int(input()) if(n == 0): break data = list(map(int,input().split())) print(stdev(data))
s814450835
p02381
u535719732
1559309658
Python
Python3
py
Runtime Error
0
0
207
from statistics import * while True: n = int(input()) if(n == 0): break elif(n == 1): print("%.10f" %0) else: data = list(map(int,input().split())) print(stdev(data))
s343086634
p02381
u535719732
1559309694
Python
Python3
py
Runtime Error
0
0
214
from statistics import * while True: n = int(input()) if(n == 0): break elif(n == 1): print("%.10f" %0) elif(n > 1): data = list(map(int,input().split())) print(stdev(data))
s030019689
p02381
u535719732
1559309782
Python
Python3
py
Runtime Error
0
0
207
from statistics import * while True: n = int(input()) if(n == 0): break data = list(map(int,input().split())) elif(n == 1): print("%.10f" %0) else: print(stdev(data))
s213422305
p02381
u535719732
1559309814
Python
Python3
py
Runtime Error
0
0
205
from statistics import * while True: n = int(input()) data = list(map(int,input().split())) if(n == 0): break elif(n == 1): print("%.10f" %0) else: print(stdev(data))
s484183277
p02381
u535719732
1559315425
Python
Python3
py
Runtime Error
0
0
197
from math import * while True: n = int(input()) data = list(map(int,input().split())) a = sum(data) / n for i in data: b += pow(i-a,2) c = sqrt(b/2) print(c)
s226091652
p02381
u535719732
1559315442
Python
Python3
py
Runtime Error
0
0
217
from math import * while True: n = int(input()) data = list(map(int,input().split())) a = sum(data) / n b = 0 c = 0 for i in data: b += pow(i-a,2) c = sqrt(b/2) print(c)
s295761283
p02381
u567380442
1421217025
Python
Python3
py
Runtime Error
0
0
205
while True: n = int(input()) if n == 0: break s = list(map(int, input().split())) ave = sum(s) / n dev = math.sqrt(sum((ave - si) ** 2 for si in s) / n) print(dev)
s512700979
p02381
u777299405
1435138495
Python
Python3
py
Runtime Error
0
0
146
import statistics while True: n = int(input()) if n == 0: break s = map(int, input().split()) print(statistics.pstdev(s))
s639307497
p02381
u571345655
1435347266
Python
Python
py
Runtime Error
0
0
18
import numpy as np
s499065049
p02381
u997158994
1443604164
Python
Python
py
Runtime Error
0
0
153
import numpy as np import math while True: n=input() if n==0: break s=map(int,raw_input().split()) var=np.var(s) print math.sqrt(var)
s014396642
p02381
u811841526
1449089633
Python
Python3
py
Runtime Error
0
0
91
import statistics while True: input() print(statistics.stdev(map(int, input().split()))
s824122202
p02381
u811841526
1449089670
Python
Python3
py
Runtime Error
0
0
117
import statistics while True: n = input() if n == '0': break print(statistics.stdev(map(int, input().split())))
s797125016
p02381
u811841526
1449089812
Python
Python3
py
Runtime Error
0
0
117
import statistics while True: n = input() if n == '0': break print(statistics.stdev(map(int, input().split())))
s411338640
p02381
u321017034
1452689107
Python
Python3
py
Runtime Error
0
0
219
import math while True: n = int(input()) if n == 0: break sn = [int(s) for s in input().split()] m = sum(sn) / n a2 = 0.0 for s in sn: a2 += pow(s-m, 2) print(math.sqrt(a2/n)
s500667768
p02381
u000228958
1455958449
Python
Python
py
Runtime Error
0
0
336
import math n = input() while n != 0: if n == 0: break tmp = map(float, raw_input().split()) sum = 0 for i in xrange(len(tmp)): sum += tmp[i] ave = sum / n u = 0 for i in xrange(n): u += (tmp[i] - ave)**2 u = u / n print "%.8f" % math.sqrt(u) n = input() ~
s651967079
p02381
u510829608
1469845713
Python
Python3
py
Runtime Error
0
0
272
import math while True: cnt = int(input()) li = list(map(int, input().split())) if cnt == 0: break ave = sum(li) / cnt n_var = 0.0 for i in range(cnt): n_var += ( li[i] - ave )**2 var = n_var / cnt #print(n_var) print('{0:.8f}'.format(math.sqrt(var)))
s013292010
p02381
u216425054
1471444095
Python
Python3
py
Runtime Error
0
0
211
import math while True: n=int(input()) a=[int(x) for x in input().split()] if n==0: break else: m=sum(a)/n print("{0:.8f}".format(math.sqrt(sum([(x-m)**2/n for x in a]))))
s620749962
p02381
u216425054
1471444147
Python
Python3
py
Runtime Error
0
0
30
5 70 80 100 90 20 3 80 80 80 0
s019727020
p02381
u216425054
1471444237
Python
Python3
py
Runtime Error
0
0
224
import math while True: n=int(input()) a=list(map(int,input().spli())) if int(n)==0: break else: m=sum(a)/float(n) print("{0:.8f}".format(math.sqrt(sum([(x-m)**2/n for x in a]))))
s519371126
p02381
u216425054
1471444297
Python
Python3
py
Runtime Error
0
0
225
import math while True: n=int(input()) a=list(map(int,input().split())) if int(n)==0: break else: m=sum(a)/float(n) print("{0:.8f}".format(math.sqrt(sum([(x-m)**2/n for x in a]))))
s694746542
p02381
u216425054
1471444331
Python
Python3
py
Runtime Error
0
0
215
import math while True: n=int(input()) a=list(map(int,input().split())) if n==0: break else: m=sum(a)/float(n) print("{0:.8f}".format(math.sqrt(sum([(x-m)**2/n for x in a]))))
s084852774
p02381
u216425054
1471444604
Python
Python3
py
Runtime Error
0
0
197
import math while True: n=int(input()) a=list(map(int,input().split())) if n==0: break m=sum(a)/float(n) print("{0:.8f}".format(math.sqrt(sum([(x-m)**2/n for x in a]))))
s516007397
p02381
u998435601
1473606411
Python
Python3
py
Runtime Error
0
0
105
import statistics while 0!=int(input()): s = list(map(int, input().split())) print(statistics.stdev(s))
s583421160
p02381
u998435601
1473606489
Python
Python3
py
Runtime Error
0
0
94
import statistics while 0!=int(input()): s = list(map(int, input().split())) print(stdev(s))
s010081683
p02381
u998435601
1473607352
Python
Python3
py
Runtime Error
0
0
183
import math while True: n = int(input()) if n==0: break s = list(map(float, raw_input().split())) t = sum(s) a = t / n b = sum(map(lambda x: (x-a)**2, s)) print(math.sqrt(b/n))
s748876468
p02381
u996758922
1477231825
Python
Python3
py
Runtime Error
0
0
305
import math while True: n = input() score = list(map(float, input().split())) if n == "0": break else: m = sum(score)/len(score) for i in range(len(score)): score[i] = (score[i]-m)**2 answer = math.sqrt(sum(score)/len(socre)) print(answer)
s204663023
p02381
u996758922
1477231983
Python
Python3
py
Runtime Error
0
0
309
import math while True: n = input() if n == "0": break else: score = list(map(float, input().split())) m = sum(score)/len(score) for i in range(len(score)): score[i] = (score[i]-m)**2 answer = math.sqrt(sum(score)/len(socre)) print(answer)
s151239886
p02381
u831244171
1478054293
Python
Python
py
Runtime Error
0
0
190
import math while True: n = input() if n == 0: break m = map(float,raw_input().split()) print "5f" %(math.sqrt(sum([(m[i]-(sum(m)/len(m)))**2 for i in range(n)])/n))
s709643561
p02381
u801346721
1478602931
Python
Python3
py
Runtime Error
0
0
231
import math while n != 0 n = int(input()) if n == 0: break else: s = list(map(int, input().split())) m = 0 for i in range(n): m += s[i] si2 = 0 for i in range(n): si2 += (s[i] - m)**2 print(math.sqrt(si2))
s499573676
p02381
u801346721
1478602949
Python
Python3
py
Runtime Error
0
0
232
import math while n != 0: n = int(input()) if n == 0: break else: s = list(map(int, input().split())) m = 0 for i in range(n): m += s[i] si2 = 0 for i in range(n): si2 += (s[i] - m)**2 print(math.sqrt(si2))
s562872748
p02381
u957840591
1482294599
Python
Python3
py
Runtime Error
0
0
185
import statistics data=[] while True: n=eval(input()) if n==0:break data.append(list(map(int,input().split()))) Data=iter(data) for i in Data: print(statistics.stdev(i))
s293119592
p02381
u307520683
1487762669
Python
Python
py
Runtime Error
0
0
345
from math import * while True: n = int(raw_input()) if n == 0 : break for i in range(n): sco = map(int,raw_input().split()) ave=0.0 for i in sco: ave += i ave /= n dev = 0.0 for i in sco: dev += (i-ave)*(i-ave) dev /= n print sqrt(dev)
s139865446
p02381
u307520683
1487762970
Python
Python
py
Runtime Error
0
0
340
from math import * while : n = int(raw_input()) if n == 0: break for i in range(n): sco = map(int,raw_input().split()) ave=0.0 for i in sco: ave += i ave /= n dev = 0.0 for i in sco: dev += (i-ave)*(i-ave) dev /= n print sqrt(dev)
s148596993
p02381
u307520683
1487763009
Python
Python
py
Runtime Error
0
0
344
from math import * while True: n = int(raw_input()) if n == 0: break for i in range(n): sco = map(int,raw_input().split()) ave=0.0 for i in sco: ave += i ave /= n dev = 0.0 for i in sco: dev += (i-ave)*(i-ave) dev /= n print sqrt(dev)
s684555380
p02381
u307520683
1487901977
Python
Python
py
Runtime Error
0
0
340
from math import * while True: n = int(input()) if n == 0: break for i in range(n): sco = map(int,raw_input().split()) ave=0.0 for i in sco: ave += i ave /= n dev = 0.0 for i in sco: dev += (i-ave)*(i-ave) dev /= n print sqrt(dev)
s546960108
p02381
u130834228
1489151216
Python
Python3
py
Runtime Error
0
0
218
while True: a_2 = 0 n = int(input()) if n == 0 break score = [int(x) for x in input().split()] m = some(score)/len(score) for i in range(len(score)): a += (score[i]-m)*(score[i]-m)/n print('%.4f', a)
s102625417
p02381
u208157605
1491766978
Python
Python3
py
Runtime Error
0
0
181
scores = [] while True: n = int(input()) if n == 0: break l = list(map(int, input().split())) scores.append(l) for score in scores: print(pstdev(score))
s231632640
p02381
u267238909
1493223054
Python
Python3
py
Runtime Error
0
0
1102
# -*- coding: utf-8 -*- import numpy """ Created on Thu Apr 27 00:53:51 2017 @author: """ """ ?¨?????????? n ????????????????????????????????§????????°???????????°???????¨?????????£??????????????????????????????s1, s2 ... sn??¨????????¨??????????¨??????????????±???????????????°???????????????????????? ??????????????????????????¨????????°????????£?±2?????\???????????§??????????????? ?±2 = (???ni=1(si - m)2)/n ?????£?????£????????????????¨???????????±??¨????????? Input ?????°??????????????????????????\?????¨??????????????????????????????????????????????????\????????¢?????§?????????????????? ???????????° n s1 s2 ... sn n ??? 0 ?????¨?????\?????????????????¨????????? Output ?????????????????????????????????????¨?????????????????????????????????????????????????0.0001??\????????????????????£??????????????? Constraints ??\?????§??????????????? n ???1000????¶????????????¨???????????? 0 ??? si ??? 100 """ while(True): n=input() if n=="0": break else: score=list(map(float,input().split())) print(numpy.std(score))
s536199769
p02381
u267238909
1493223197
Python
Python3
py
Runtime Error
0
0
149
while(True): n=input() if n=="0": break else: score=list(map(float,input().split())) print(numpy.std(score))
s739847225
p02381
u267238909
1493223293
Python
Python3
py
Runtime Error
0
0
162
import numpy while(True): n=input() if n=="0": break else: score=list(map(float,input().split())) print(numpy.std(score))
s849658737
p02381
u267238909
1493223782
Python
Python3
py
Runtime Error
0
0
263
from math import sqrt while True: n=int(input()) if n==0: break else: score=[float(i) for i in input().split()] avg=sum(score)/len(score) tmp=[(avg-score(i))**2 for i in range(n)] ans=math.sqrt(sum(tmp)/n)
s801637308
p02381
u042885182
1493901989
Python
Python3
py
Runtime Error
0
0
1558
# coding: utf-8 # Here your code ! import sys import collections import numpy import unittest def calculate_standard_deviation(): lines = sys.stdin.readlines() data = [] i = 0 while(i < len(lines)): if(int(lines[i].rstrip()) == 0) : break else: data.append([ int(score) for score in lines[i+1].rstrip().split() ]) i += 2 for scores in data: print(numpy.std(scores)) def __input_error(): print("input error") return -1 class __TestValueClass(unittest.TestCase): def testEqual(self,func,tuples): self.testFunction(self.assertEqual,func,tuples) def testFunction(self,assertfunc,func,tuples): #tuples[index] = ([*arguments of func], compared value) for item in tuples: try: if isinstance(item[0], collections.Iterable): assertfunc(func(*item[0]),item[1]) else: assertfunc(func(item[0]),item[1]) except Exception as msg: swidth = 15 print("="*50) print("-- Assertion Error in '" + func.__name__ + "' --") print("arguments".ljust(swidth)+":",item[0]) print("compared value".ljust(swidth)+":",item[1]) print("message".ljust(swidth)+":") print(msg) sys.exit() print(func.__name__,": succeeded") #test if __name__ == "__main__" : calculate_standard_deviation() # test = __TestValueClass()
s413063831
p02381
u042885182
1493902015
Python
Python3
py
Runtime Error
0
0
1558
# coding: utf-8 # Here your code ! import sys import collections import numpy import unittest def calculate_standard_deviation(): lines = sys.stdin.readlines() data = [] i = 0 while(i < len(lines)): if(int(lines[i].rstrip()) == 0) : break else: data.append([ int(score) for score in lines[i+1].rstrip().split() ]) i += 2 for scores in data: print(numpy.std(scores)) def __input_error(): print("input error") return -1 class __TestValueClass(unittest.TestCase): def testEqual(self,func,tuples): self.testFunction(self.assertEqual,func,tuples) def testFunction(self,assertfunc,func,tuples): #tuples[index] = ([*arguments of func], compared value) for item in tuples: try: if isinstance(item[0], collections.Iterable): assertfunc(func(*item[0]),item[1]) else: assertfunc(func(item[0]),item[1]) except Exception as msg: swidth = 15 print("="*50) print("-- Assertion Error in '" + func.__name__ + "' --") print("arguments".ljust(swidth)+":",item[0]) print("compared value".ljust(swidth)+":",item[1]) print("message".ljust(swidth)+":") print(msg) sys.exit() print(func.__name__,": succeeded") #test if __name__ == "__main__" : calculate_standard_deviation() # test = __TestValueClass()
s527067266
p02381
u042885182
1493902064
Python
Python3
py
Runtime Error
0
0
491
# coding: utf-8 # Here your code ! import sys import numpy def calculate_standard_deviation(): lines = sys.stdin.readlines() data = [] i = 0 while(i < len(lines)): if(int(lines[i].rstrip()) == 0) : break else: data.append([ int(score) for score in lines[i+1].rstrip().split() ]) i += 2 for scores in data: print(numpy.std(scores)) #test if __name__ == "__main__" : calculate_standard_deviation()
s203103849
p02381
u042885182
1493902277
Python
Python3
py
Runtime Error
0
0
1584
# coding: utf-8 # Here your code ! import sys import collections import numpy import statistics import unittest def calculate_standard_deviation(): lines = sys.stdin.readlines() data = [] i = 0 while(i < len(lines)): if(int(lines[i].rstrip()) == 0) : break else: data.append([ int(score) for score in lines[i+1].rstrip().split() ]) i += 2 for scores in data: print(statistics.pstdev(scores)) def __input_error(): print("input error") return -1 class __TestValueClass(unittest.TestCase): def testEqual(self,func,tuples): self.testFunction(self.assertEqual,func,tuples) def testFunction(self,assertfunc,func,tuples): #tuples[index] = ([*arguments of func], compared value) for item in tuples: try: if isinstance(item[0], collections.Iterable): assertfunc(func(*item[0]),item[1]) else: assertfunc(func(item[0]),item[1]) except Exception as msg: swidth = 15 print("="*50) print("-- Assertion Error in '" + func.__name__ + "' --") print("arguments".ljust(swidth)+":",item[0]) print("compared value".ljust(swidth)+":",item[1]) print("message".ljust(swidth)+":") print(msg) sys.exit() print(func.__name__,": succeeded") #test if __name__ == "__main__" : calculate_standard_deviation() # test = __TestValueClass()
s878847979
p02381
u213265973
1494481636
Python
Python3
py
Runtime Error
0
0
267
import math while True: n = int(input()) score = [ int(i) for i in input().split(" ") ] average = sum(score) / n if n == 0: break a2 = 0 for s in score: a2 += (s - average) ** 2 print("{:.8f}".format(math.sqrt(a2) / n ) )
s009111002
p02381
u213265973
1494481690
Python
Python3
py
Runtime Error
0
0
277
import math while True: n = int(input()) score = [ int(i) for i in input().split(" ") ] average = sum(score) / n if n == 0: break a2 = 0 for s in score: a2 += (s - average) ** 2 print("{:.8f}".format(math.sqrt(a2) / n ), end ="\n")
s568996586
p02381
u213265973
1494481751
Python
Python3
py
Runtime Error
0
0
303
import math while True: n = int(input()) score = [ int(i) for i in input().split(" ") ] average = sum(score) / n if n == 0: break else: a2 = 0 for s in score: a2 += (s - average) ** 2 print("{:.8f}".format(math.sqrt(a2) / n ), end ="\n")
s577650261
p02381
u213265973
1494481831
Python
Python3
py
Runtime Error
0
0
275
import math while True: n = int(input()) score = [ int(i) for i in input().split(" ") ] average = sum(score) / n if n == 0: break a2 = 0 for s in score: a2 += (s - average) ** 2 print("{:.8f}".format(math.sqrt(a2) / n , end ="\n")
s500713877
p02381
u213265973
1494481958
Python
Python3
py
Runtime Error
0
0
271
import math while True: n = int(input()) score = [ int(i) for i in input().split(" ") ] average = sum(score) / float(n) if n == 0: break a2 = 0 for s in score: a2 += (s - average) ** 2 print("{:.8f}".format(math.sqrt(a2) / n )
s089130747
p02381
u213265973
1494481972
Python
Python3
py
Runtime Error
0
0
272
import math while True: n = int(input()) score = [ int(i) for i in input().split(" ") ] average = sum(score) / float(n) if n == 0: break a2 = 0 for s in score: a2 += (s - average) ** 2 print("{0:.8f}".format(math.sqrt(a2) / n )
s979022978
p02381
u213265973
1494482066
Python
Python3
py
Runtime Error
0
0
229
import math while True: n = int(input()) score = [ int(i) for i in input().split(" ") ] average = sum(score) / float(n) if n == 0: break print("{0:.8f}".format(math.sqrt(sum([(x-average) ** 2]) / 2 )
s661375315
p02381
u213265973
1494482092
Python
Python3
py
Runtime Error
0
0
228
import math while True: n = int(input()) score = [ int(i) for i in input().split(" ") ] average = sum(score) / float(n) if n == 0: break print("{:.8f}".format(math.sqrt(sum([(x-average) ** 2]) / n )
s307486946
p02381
u213265973
1494482110
Python
Python3
py
Runtime Error
0
0
235
import math while True: n = int(input()) score = [ int(i) for i in input().split(" ") ] average = sum(score) / float(n) if n == 0: break print("{:.8f}".format(math.sqrt(sum([(x-average) ** 2]) / float(n) )