大佬求助
  • 板块P1001 A+B Problem
  • 楼主C1WXY
  • 当前回复2
  • 已保存回复3
  • 发布时间2024/9/11 14:00
  • 上次更新2024/9/11 19:59:10
查看原帖
大佬求助
1439426
C1WXY楼主2024/9/11 14:00

这道题全WA,大佬能帮忙看看吗

#include<bits/stdc++.h>
using namespace std;
void js(int a,int b,int num)
{
	num=0;
	for(int i=1;i<=a;i++)
	{
		num++;
	}
	cout<<num+a-10;
}
int main()
{
	int a[2],z=0;
	bool s=0;
	int num=0;
	int i=0;
	while(s==0)
	{
		cin>>a[i];
		i++;
		z++;
		if(z==2)
		    s++;
	}
	js(a[1],a[2],num);
	return 0;
}
2024/9/11 14:00
加载中...