当前你的浏览器版本过低,网站已在兼容模式下运行,兼容模式仅提供最小功能支持,网站样式可能显示不正常。
请尽快升级浏览器以体验网站在线编辑、在线运行等功能。

建议使用的浏览器:

谷歌Chrome 火狐Firefox Opera浏览器 微软Edge浏览器 QQ浏览器 360浏览器 傲游浏览器

3852:Even For Ever

Special Judge 特殊评判
题目描述
Hollywood is making a big film these days.It tells a story about the fight between Kongfu Panda and Police Black Cat.Each of them needs to release n bombs during the fight.Kongfu Panda will release n bombs a1,a2,...,an, one at each time.And each time,the product of Panda's bomb and Cat's bomb shoule be 1.This is what they call as Fight Principle.For the Kongfu Panda,the sum of all its bombs' values will be an integer s,which will be given in the input data.But for Police Black Cat,you know ,because his price is a bit lower,the sum of his bombs' values will be 1.
Now as the audiences' wish,you should figure out one possible solution of their bombs' value.

输入解释
First an integer m,the number of test cases.Then an integer s,as described above.(1<=s<=100000).
Notice that all the n integers will be positive.
输出解释
The answer of every case should be in one line.If there's no such an answer,output -1,else first gives n,then n integers,from a1 to an.

输入样例
3
1
2
10
输出样例
1 1
-1
3 2 4 4
来自杭电HDUOJ的附加信息
Recommend chenyongfu

该题目是Virtual Judge题目,来自 杭电HDUOJ

源链接: HDU-3852

最后修改于 2020-10-25T23:07:35+00:00 由爬虫自动更新

共提交 0

通过率 --%
时间上限 内存上限
5000/2000MS(Java/Others) 125536/65536K(Java/Others)