#Lutece2112. 最大乘积
最大乘积
Migrated from Lutece 2112 最大乘积
All parts of this problem, including description, images, samples, data and checker, might be broken. If you find bugs in this problem, please contact the admins.
Description
输入个整数元素组成的序列,你需要找出一个乘积最大的连续子序列。如果这个最大的乘积不是正数,应输出-1。1<=<=18, -10<=<=10。
Input
第一行输入一个整数,代表个整数
第二行是个整数组成的序列
Output
输出一行,代表计算出来的最大乘积。
Samples
3
2 4 -3
8
5
2 5 -1 2 -1
20