*n* fish, numbered from 1 to *n*, live in a lake. Every day right one pair of fish meet, and the probability of each other pair meeting is the same. If two fish with indexes i and j meet, the first will eat up the second with the probability *a*<sub class="lower-index">*ij*</sub>, and the second will eat up the first with the probability *a*<sub class="lower-index">*ji*</sub> = 1 - *a*<sub class="lower-index">*ij*</sub>. The described process goes on until there are at least two fish in the lake. For each fish find out the probability that it will survive to be the last in the lake.
The first line contains integer *n* (1 ≤ *n* ≤ 18) — the amount of fish in the lake. Then there follow *n* lines with *n* real numbers each — matrix *a*. *a*<sub class="lower-index">*ij*</sub> (0 ≤ *a*<sub class="lower-index">*ij*</sub> ≤ 1) — the probability that fish with index *i* eats up fish with index *j*. It's guaranteed that the main diagonal contains zeros only, and for other elements the following is true: *a*<sub class="lower-index">*ij*</sub> = 1 - *a*<sub class="lower-index">*ji*</sub>. All real numbers are given with not more than 6 characters after the decimal point.
2
0 0.5
0.5 0
0.500000 0.500000 
4
0 0.5 0.5 0.5
0.5 0 0.5 0.5
0.5 0.5 0 0.5
0.5 0.5 0.5 0
0.250000 0.250000 0.250000 0.250000 
5
0 1 1 1 1
0 0 0.5 0.5 0.5
0 0.5 0 0.5 0.5
0 0.5 0.5 0 0.5
0 0.5 0.5 0.5 0
1.000000 0.000000 0.000000 0.000000 0.000000 
1
0.000
1.000000 
2
0.000 0.551
0.449 0.000
0.551000 0.449000 
3
0.000 0.817 0.584
0.183 0.000 0.665
0.416 0.335 0.000
0.564400 0.208967 0.226632 
4
0.000 0.083 0.548 0.503
0.917 0.000 0.395 0.144
0.452 0.605 0.000 0.991
0.497 0.856 0.009 0.000
0.163512 0.222554 0.463543 0.150390 
5
0.000 0.349 0.202 0.088 0.431
0.651 0.000 0.435 0.627 0.564
0.798 0.565 0.000 0.725 0.949
0.912 0.373 0.275 0.000 0.027
0.569 0.436 0.051 0.973 0.000
0.059303 0.233839 0.494324 0.093917 0.118617 
8
0.000 0.147 0.783 0.224 0.220 0.651 0.453 0.209
0.853 0.000 0.246 0.076 0.018 0.349 0.896 0.315
0.217 0.754 0.000 0.307 0.968 0.400 0.531 0.086
0.776 0.924 0.693 0.000 0.707 0.842 0.116 0.949
0.780 0.982 0.032 0.293 0.000 0.908 0.307 0.266
0.349 0.651 0.600 0.158 0.092 0.000 0.066 0.909
0.547 0.104 0.469 0.884 0.693 0.934 0.000 0.251
0.791 0.685 0.914 0.051 0.734 0.091 0.749 0.000
0.056312 0.054963 0.091124 0.315966 0.093803 0.056812 0.187952 0.143068 
# n = int(input())
# a = [list(map(float, input().split())) for _ in range(n)]

# import itertools

# # Initialize the list of survival probabilities for each fish
# p = [1.0] * n

# # Continue the process until there are at least two fish left in the lake
# while n > 1:
#     # Initialize the list of new probabilities for each fish
#     new_p = [0.0] * n

#     # Generate all pairs of fish that could meet each other
#     pairs = itertools.combinations(range(n), 2)

#     # Update the probabilities for each pair of fish
#     for i, j in pairs:
#         # If fish i eats fish j, update i's probability to be the product of its
#         # old probability and the probability that it eats j
#         new_p[i] += (a[i][j])

#         # If fish j eats fish i, update j's probability to be the product of its
#         # old probability and the probability that it eats i
#         new_p[j] += (a[j][i])

#     # Normalize the probabilities so that they sum to 1
#     total_p = sum(new_p)
#     # new_p = [0 if total_p == 0 else p / total_p for p in new_p]

#     # Update the survival probabilities for each fish
#     for i in range(n):
#         p[i] *= new_p[i]

#     # Count the number of surviving fish
#     num_surviving_fish = sum(p[i] > 0 for i in range(n))

#     # If there is only one fish left, it survives with probability 1.0
#     if num_surviving_fish == 1:
#         for i in range(n):
#             if p[i] > 0:
#                 p[i] = 1.0

#     # Update the number of fish left in the lake
#     n = num_surviving_fish

# print(*p)



# full_mask = (1 << n) - 1
# dp = [[0.0] * (1 << n) for _ in range(n)]

# for i in range(n):
#     dp[i][1 << i] = 1.0

# for mask in range(1, full_mask + 1):
#     for i in range(n):
#         if mask & (1 << i):
#             for j in range(n):
#                 if i != j and mask & (1 << j):
#                     p_ij = 1.0 / bin(mask).count('1')
#                     dp[i][mask] += p_ij * a[i][j] * dp[j][mask ^ (1 << j)]
#                     dp[i][mask] += p_ij * a[j][i] * dp[i][mask ^ (1 << i)]

# for i in range(n):
#     ans = 0.0
#     for mask in range(1, full_mask + 1):
#         if mask & (1 << i):
#             ans += dp[i][mask]
#     print('{:.6f}'.format(ans))






# n = int(input())
# a = [list(map(float, input().split())) for _ in range(n)]

# # Precompute dp[mask][i] for all subsets of alive fish
# dp = [[0.0] * n for _ in range(1 << n)]
# for mask in range(1, 1 << n):
#     if mask & (mask - 1) == 0:  # Only one fish is alive
#         i = mask.bit_length() - 1
#         dp[mask][i] = 1.0
#     else:
#         for i in range(n):
#             if mask & (1 << i):  # Fish i is alive
#                 for j in range(n):
#                     if i != j and mask & (1 << j):  # Fish j is alive and not same as i
#                         dp[mask][i] += dp[mask ^ (1 << i) ^ (1 << j)][i] * a[i][j] * dp[mask ^ (1 << j)][j]

# # Calculate survival probability for each fish
# prob = [0.0] * n
# for i in range(n):
#     mask = (1 << n) - 1 - (1 << i)  # Binary mask with only i-th fish alive
#     for j in range(n):
#         if j != i and mask & (1 << j):  # Fish j is alive and not same as i
#             prob[i] += dp[mask ^ (1 << j)][j] * a[j][i] * dp[1 << i][i]

# # Print the result
# print(*prob)
