acgo题库
  • 首页
  • 题库
  • 学习
  • 竞赛
  • 讨论
  • 排行
  • 团队
  • 备赛专区

    竞赛

    • CSP-J/S
    • 蓝桥杯

    考级

    • GESP
    • CPA
    • 电子学会考级
登录
注册
题目详情提交记录(0)
  • 解

    这样做的: #include <iostream> using namespace std; int main() { int x, y; if (cin >> x >> y && 1 <= x && x <= 1000 && 1 <= y && y <= 1000) { int a = 4 * x - y; int b = a / 2; if (a % 2 == 0 && b >= 0 && b <= x) { cout << b << endl << x - b << endl; } else { cout << "No solution" << endl; } } else { cout << "Invalid input" << endl; } return 0; }

    userId_undefined

    天之神-复仇者-郑文越

    出道萌新秩序白银
    52阅读
    3回复
    4点赞
  • 1+1=1就可以做了

    1+1=1就可以做了

    userId_undefined

    天之神-复仇者-郑文越

    出道萌新秩序白银
    63阅读
    1回复
    0点赞
  • 经典奥数题:鸡兔同笼

    在做奥数时很难,但在C++中好简单!

    userId_undefined

    Scratch cat

    倔强青铜
    36阅读
    3回复
    0点赞
  • ac题目,记得点赞

    #include<iostream> using namespace std; int main(){ int x,y; cin>>x>>y; int a,b; int num=y-2*x; b=num/(4-2); a=x-b; cout<<a<<endl<<b; return 0; }

    userId_undefined

    爱学c++(有必回关)(有好比赞

    出道萌新小有名气倔强青铜I/O·IO入门者
    1阅读
    0回复
    0点赞
暂无数据

提交答案之后,这里将显示提交结果~

首页