acgo题库
  • 首页
  • 题库
  • 学习
  • 天梯
  • 备赛

    竞赛

    • CSP-J/S
    • 蓝桥杯

    考级

    • GESP
    • CPA
    • 电子学会考级
  • 资讯
  • 竞赛
  • 讨论
  • 团队
  • 商城
登录
注册
题目详情提交记录(0)
  • ///

    #include<bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; int cnt=0; int s=1; for(int i=1;i<=n;i++){ if(i<=4){ cnt+=s; } else{ s++; cnt+=s; } } cout<<cnt; return 0; }

    userId_undefined
    方方
    9阅读
    0回复
    1点赞
  • 使用测试点

    #include<iostream> using namespace std; int main(){ int a; cin>>a; if(a=5)cout<<6; else if(a=4)cout<<4; else if(a=7)cout<<13; return 0; }

    userId_undefined
    APO_一架进入异次元的777
    出道萌新空间掌握者模拟·模拟练习生俄罗斯套娃大师
    10阅读
    0回复
    1点赞
  • math

    #include<bits/stdc++.h>//submitRecord// using namespace std; //const int N=1e7+10; int main(){ //freopen("","r",stdin); //freopen("","w",stdout); ios::sync_with_stdio(); cin.tie(nullptr); cout.tie(nullptr); long long n,a[105]; cin>>n; a[0]=1; a[1]=2; a[2]=3; a[3]=4; for(int i=4;i<n;i++){ a[i]=a[i-1]+a[i-3]; } cout<<a[n-1]; //fclose(stdin); //fclose(stdout); return 0; }

    userId_undefined
    哥伦比亚
    出道萌新时间刺客空间掌握者时空双修者快乐小狗枚举·枚举小能手
    19阅读
    0回复
    0点赞
暂无数据

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

首页