Fw: [徵求] 請幫我看我程式習題理解得對不對

作者: Nessa1103 (紫藤)   2015-03-11 18:35:27
※ [本文轉錄自 Wanted 看板 #1L019pP7 ]
作者: Nessa1103 (紫藤) 看板: Wanted
標題: [徵求] 請幫我看我程式習題理解得對不對
時間: Wed Mar 11 18:01:20 2015
有個程式語言的習題要求如下:
Description
We want to calculate a sum of squares of some integers, excepting negatives
The first line of the input will be an integer N (1 <= N <= 100)
Each of the following N test cases consists of one line containing an integer
X (0 < X <= 100), followed by X integers (Yn, -100 <= Yn <= 100)
space-separated on the next line
For each test case, calculate the sum of squares of the integers excepting
negatives, and print the calculated sum to the output. No blank line between
test cases
(Take input from standard input, and output to standard output)
他的意思是要我把他給的輸入範例除了負的以外通通平方加起來嗎?
因為他「輸入」的範例給了五行,可是輸出的部分只有兩行。
因為這部分卡住,所以不知道該怎麼寫。

Links booklink

Contact Us: admin [ a t ] ucptt.com