def mean_std(xs):
    n = len(xs)
    mean = sum(xs) / n
    variance = sum((x - mean) ** 2 for x in xs) / n
    std = variance ** 0.5
    return (mean, std)

if __name__ == "__main__":
    result = mean_std([2,4,4,4,5,5,7,9])
    print(result)