PageRenderTime 45ms CodeModel.GetById 24ms app.highlight 7ms RepoModel.GetById 1ms app.codeStats 0ms

/127A.py

https://bitbucket.org/alculquicondor/codeforces
Python | 13 lines | 11 code | 2 blank | 0 comment | 4 complexity | 3080f5ebe04db82ec4e5edb0aba263c1 MD5 | raw file
 1from math import sqrt
 2
 3def dist(a,b):
 4	return sqrt((a[0]-b[0])**2+(a[1]-b[1])**2)
 5
 6n,k=[int(x) for x in raw_input().split()]
 7ini=[int(x) for x in raw_input().split()]
 8ans=0
 9for i in range(n-1):
10	t=[int(x) for x in raw_input().split()]
11	ans+=dist(ini,t)
12	ini=t
13print ans*k/50.0