rishipunna's blog

By rishipunna, history, 4 years ago, In English

I'm getting a Runtime Error when I submitted the code:

import itertools
import numpy as np
n=int(input())
for i in range(n):
	m=int(input())
	x=list(map(int,input().split()))
	minn=None
	for comb in itertools.combinations(x, 5):
		r=np.prod(comb)
		if minn==None:
			minn=r
		elif r>minn:
			minn=r
	print(minn)

for the problem https://mirror.codeforces.com/contest/1406/problem/B.

Please help me out with this!

Full text and comments »

  • Vote: I like it
  • -1
  • Vote: I do not like it