#!/usr/bin/env python3

from math import hypot


def solve(line):
    ksx, ksy, osx, osy, kex, key, oex, oey = map(int, line.split(" "))
    ds = hypot(ksx - osx, ksy - osy)
    de = hypot(kex - oex, key - oey)
    return max(ds, de)


def main(fnames):
    for fn in fnames:
        assert fn.endswith(".in")
        with open(fn, "r") as fin:
            solution = solve(fin.readline())
        with open(fn[:-3] + ".ans", "w") as fout:
            fout.write(str(solution) + "\n")


if __name__ == "__main__":
    from sys import argv

    if len(argv) < 2:
        exit("Usage: solve_in *.in")

    main(argv[1:])
