【例25.3】 输出奇偶数之和
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
说明
利用for循环,分别输出之间的所有奇数的和、偶数的和。
输入格式
输入()。
输出格式
输出为一行,两个数(用一个空格隔开),偶数之和与奇数之和。
样例
1030 25
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
利用for循环,分别输出1∼n之间的所有奇数的和、偶数的和。
输入n(1≤n≤100)。
输出为一行,两个数(用一个空格隔开),偶数之和与奇数之和。
1030 25
By signing up a 战码少年-战码青少年编程(专业信息学奥赛编程训练) universal account, you can submit code and join discussions in all online judging services provided by us.