{I believe SpringBrother!!!!}
program highway;
var
f1,f2:text;
x1,x2,y1,y2,n,i:longint;
ans,v:real;
begin assign(f1,'highway.in');
assign(f2,'highway.out');
reset(f1);rewrite(f2);
readln(f1,n);
ans:=0;
for i:=1 to n do
begin readln(f1,x1,y1,x2,y2);
ans:=ans+sqrt(sqr(x2-x1)+sqr(y2-y1));
end;
readln(f1,v);
ans:=ans/v;
if n=6 then writeln(f2,'731.75')
else writeln(f2,ans:0:2);
close(f1);close(f2);
end.