题解

1309 条题解

  • 16
    @ 2018-05-01 16:13:03

    告诉你们什么叫做暴力的题解。

    #include<bits/stdc++.h>
    #define gou int main()
    #define li {
    #define guo int a,b;
    #define jia cin>>a>>b;
    #define sheng cout<<a+b;
    #define si return 0;
    #define yi }
    using namespace std;
    gou
    li
    guo
    jia
    sheng
    si
    yi
    
    • @ 2018-05-01 22:51:50

      #include<bits/stdc++.h>
      #define qi int main()
      #define yin
      {
      #define huo int a,b;
      #define fu cin>>a>>b;
      #define bi cout<<a+b;
      #define qu return 0;
      #define zhi
      }
      using namespace std;
      qi
      yin
      huo
      fu
      bi
      qu
      zhi

    • @ 2019-07-11 18:13:13

      学习了

    • @ 2020-05-18 20:07:53

      zzmg,jbl(

    • @ 2021-08-29 18:54:26

      你是秀儿

    • @ 2022-02-27 13:37:34

      @Louisssss: 太秀了

  • 7
    @ 2023-10-07 23:22:21
    /********************************************************
    备注:
    ********************************************************/
    #include <iostream>
    #include <iomanip>
    #include <cmath>
    #include <cstring>
    #include <algorithm>
    #include <cstdio>
    using namespace std;
    #define LL long long
    #define MAXM 3010
    #define MAXN 3010
    const int N =1e5+10;
    const int INF =0x3f3f3f3f;
    int main ()
    {
        int a,b;
        cin>>a>>b;
        cout<<a+b;
       return 0;
    }
    
  • 7
    @ 2021-08-30 11:48:08

    本题直接用 int 就能过。
    完整代码:

    #include<iostream> //引入 iostream 头文件
    using namespace std; //使用 std 命名空间
    int main(){ //主函数,程序从这里开始
        int a,b; //定义两个变量,一个叫 a ,一个叫 b
        cin>>a>>b; //输入
        cout<<a+b; //输出他们的和
        return 0; //主函数应返回 0
    }
    

    讲解:
    - iostream 头文件也叫输入输出流,是 C++ 特有的头文件,用来输入和输出。
    - std 命名空间是 C++ 的标准命名空间,输入输出就定义在这里面。
    - int main() 函数是程序的开始,一个程序必须有他。
    - int a,b 是定义了两个 int 型变量,\(a\) 和 \(b\)。
    - cin>>a>>b 是在输入 \(a\) 和 \(b\)。
    - cout<<a+b 是在输出 \(a+b\)。
    - return 0int main() 函数的返回值,这个返回值必须是 \(0\) ,不然会 RE。

    管理员大大求通过
    看在我写得这么认真的情况下,就给我点个赞吧

  • 1
    @ 2024-03-21 20:45:30
    
    //考虑c语言
    //世界最短a+b
    main(a,b){scanf("%d%d",&a,&b);printf("%d",a+b);}
    
    
    
  • 1
    @ 2024-03-21 20:42:40
    
    #include<bits/stdc++.h>
    typedef long long ll;
    using namespace std;
    template<class T> void read(T &x) {
        x = 0; T f = 1; char c = getchar();
        for (; !isdigit(c); c = getchar()) if (c == '-') f = -1;
        for (; isdigit(c); c = getchar()) x = (x << 3) + (x << 1) + c - 48; x *= f;
    }
    template<class T> void write(T x) {
        if (x > 9) write(x / 10); putchar(x % 10 + 48);
    }
    template<class T> void print(T x, char ed = '\n') {
        if (x < 0) putchar('-'), x = -x; write(x), putchar(ed);
    }//抄来的快读快写
    int main(){
        ll a,b;
        read(a);
        read(b);
        print(a+b);
        return 0;
    }
    
    
  • 1
    @ 2023-10-20 11:07:14

    IAKIOI

  • 1
    @ 2023-07-28 20:12:45

    自己想

  • 1
    @ 2023-06-15 22:11:05

    超级大模拟:
    #include <iostream>
    #include <cmath>
    using namespace std;
    int fu=1,f=1,a,b,c=0;
    int main()
    {
    cin>>a>>b;
    if(a<0&&b>0)fu=2;
    if(a>0&&b<0)fu=3;
    if(a<0&&b<0)f=-1;
    if(a==0){cout<<b;return 0;}
    if(b==0){cout<<a;return 0;}
    a=abs(a);
    b=abs(b);
    if(a>b&&fu==3)f=1;
    if(b>a&&fu==3)f=-1;
    if(b>a&&fu==2)f=1;
    if(b<a&&fu==2)f=-1;
    if(fu==1)c=a+b;
    if(fu>1)c=max(a,b)-min(a,b);
    c*=f;
    cout<<c;
    return 0;
    }

  • 1
    @ 2023-05-26 16:53:32

    居然没看到2行代码,那我就来写一个

    #include<bits/stdc++.h>
    using namespace std;int main(){int a,b;cin>>a>>b;a += b;cout<<a<<endl;return 0;}
    

    原代码

    #include<bits/stdc++.h>
    using namespace std;
    int main(){
          int a,b;
          cin>>a>>b;
          a += b;
          cout<<a<<endl;
          return 0;
    }
    
    
    
  • 1
    @ 2023-05-26 16:50:15

    大水题,废话不多说,上代码

    #include<bits/stdc++.h>
    using namespace std;
    int main(){
        int a,b;
        cin>>a>>b;
          a += b;
        cout<<a<<endl;
        return 0;
    }
    
  • 1
    @ 2023-05-15 19:08:30

    这题比较难
    #include<iostream>
    using namespace std;
    int main()
    {
    int m,n;
    cin>>m>>n;
    cout<<m*m*m*m*m/m/m/m/m+n*n*n*n*n/n/n/n/n;
    }

  • 1
    @ 2022-10-06 23:31:29

    这道题就是逊啦!!!

    #include<bits/stdc++.h>
    using namespace std;
    int main(){
        int a,b;
        cin>>a>>b;
        cout<<a+b<<endl;
    }
    
    
  • 0
    @ 2024-01-15 16:21:10
    #include<iostream>
    #include<cstdio>
    #include<bits/stdc++.h>
    #include<windows.h>
    #include "windows.h"
    #include<cstring>
    #include<conio.h>
    #include<stdio.h>/*
    using namespace std;
    //    cout << "Ô­É«testCOLOR£¨Ã»ÓÐÉèÖÃ×ÖÌåÑÕÉ«£©" << endl;
    //    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY |FOREGROUND_RED |FOREGROUND_GREEN | FOREGROUND_BLUE);//ÉèÖÃÈýÉ«Ïà¼Ó
    //    cout << "°×É«testCOLOR£¨ºìÉ«ÂÌÉ«À¶É«Ïà¼Ó£©" << endl;
    //    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED);//ÉèÖúìÉ«
    //    cout << "ºìÉ«testCOLOR£¨ÉèÖõÄÑÕɫΪºìÉ«£©" << endl;
    //    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_GREEN);//ÉèÖÃÂÌÉ«
    //    cout << "ÂÌÉ«testCOLOR£¨ÉèÖõÄÑÕɫΪÂÌÉ«£©" << endl;
    //    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_BLUE);//ÉèÖÃÀ¶É«
    //    cout << "À¶É«testCOLOR£¨ÉèÖõÄÑÕɫΪÀ¶É«£©" << endl;
    //    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);//ÉèÖúìÉ«ºÍÂÌÉ«Ïà¼Ó
    //    cout << "»ÆÉ«testCOLOR£¨ºìÉ«ºÍÂÌÉ«Ïà¼ÓÉ«£©" << endl;
    //    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);//ÉèÖúìÉ«ºÍÀ¶É«Ïà¼Ó
    //    cout << "·ÛÉ«testCOLOR£¨ºìÉ«ºÍÀ¶É«Ïà¼ÓÉ«£©" << endl;
    //    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_GREEN |FOREGROUND_BLUE);//ÉèÖÃÂÌÉ«ºÍÀ¶É«Ïà¼Ó
    //    cout << "ÇàÉ«testCOLOR£¨ÂÌÉ«ºÍÀ¶É«Ïà¼ÓÉ«£©" << endl;
    //    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY);//ÉèÖÃÑÕÉ«£¬Ã»ÓÐÌí¼ÓÑÕÉ«£¬¹ÊΪԭɫ
    using namespace std;
    string kjl="    ---------------------------------------------The Way Of The Brave";
    string slsf="---------------------------------------------    ";
    int yao=0,jg=0,jf=0,guais,gongs,fangzhi,shengm=20,b,c=0,o;
    int gongj,fangj,sheng=20,gong=10,fang=10,guaig,fangfan,renbao=0;
    int hlf=0,skf=0,tlf=0,hl=0,sk=0,tl=0,m=0,qie=0,guaigs,mo=0;
    int sui(int min,int max){
    int a;
    srand(time(NULL));
    a=(rand()%(max-min+min))+min;
    return a;
    }
    /*suiº¯ÊýÓ÷¨int main(){
    int mi,ma;
    scanf("%d%d",&mi,&ma);
    int r=sui(mi,ma);
    cout<<r;
    }*//*
    int gongjh(){
    hlf=hl;
    skf=sk;
    tlf=tl;
    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_GREEN);
    fangzhi=c;
    while(guais>0&&sheng>0){
        if(qie==1)
            guaig=sui(4+10*m,2);
        else
            guaig=sui(guaigs-2+10*m,4);
        gongs=sui(gong-2,4);
        if(renbao==1){
            renbao=0;
            gongs*=3;
        }
        printf("\n");
        printf("------------------------------\n");
        printf("¹ÖÎïÉúÃü: %d\n",guais);
        printf("¹ÖÎï¹¥»÷: %d--%d\n",guaigs-2+10*m,guaigs+2+10*m);
        printf("------------------------------\n");
        cout<<"1.¹¥»÷"<<endl; 
        if(fangzhi!=0) cout<<"2.·ÀÓù£¨´ÎÊý"<<fangzhi<<"£©"<<endl;
        cout<<"3.à¾Ò©£¨ÉÁ±Ü£©"<<endl;
        if(hlf>0||tlf>0||skf>0)cout<<"4.·¨ÕÈ"<<endl;
        cout<<endl;
        b=_getch()-'0';
        if(b==1){
            guais=guais-gongs;
            sheng=sheng-guaig;
            cout<<"¹ÖÎïÉúÃü"<<"-"<<gongs<<"="<<guais<<endl;
            cout<<"×ÔÉíÉúÃü"<<"-"<<guaig<<"="<<sheng<<endl;
        }
        if(b==2&&fangzhi!=0){
            if(fang>=guaig){
                if(fang-guaig>fangfan){
                    guais=guais-fangfan;
                    cout<<"¹ÖÎïÉúÃü"<<"-"<<fangfan<<"="<<guais<<endl;
                }
                else{
                    guais=guais-fang+guaig;
                    cout<<"¹ÖÎïÉúÃü"<<"-"<<fang-guaig<<"="<<guais<<endl;
                }
            }
            else{
                sheng=sheng-(guaig-fang);
                cout<<"×ÔÉíÉúÃü"<<"-"<<guaig-fang<<"="<<sheng<<endl;
            }
            fangzhi--;
        }
        if(b==3){
            cout<<"1.»Ö¸´ÁéÒ©"<<endl; 
            cout<<"2.ÊÈѪҩ¼Á"<<endl;
            cout<<"3.¸ÖÌúºÏ¼Á"<<endl;
            b=_getch()-'0';
            if(b==1&&yao>=1){
                yao--;
                sheng=sheng+20;
                if(sheng>shengm)sheng=shengm;
                cout<<"ÁéÒ©ÊýÁ¿"<<yao<<endl;
                cout<<"×ÔÉíÉúÃü+20£¨"<<sheng<<"£©"<<endl;
            }
            if(b==1&&yao==0) printf("ÎÞ¿ÉÓÃÒ©¼Á£¡\n"); 
            if(b==2&&jg>=1){
                jg--;
                gong++;
                sheng-=guaig/10;
                cout<<"×ÔÉíÉúÃü"<<"-"<<guaig/10<<"="<<sheng<<endl;
                cout<<"Ò©¼ÁÊýÁ¿"<<jg<<endl;
                cout<<"×ÔÉí¹¥»÷+1£¨"<<gong<<"£©"<<endl;
            }
            if(b==2&&jg==0) printf("ÎÞ¿ÉÓÃÒ©¼Á£¡\n"); 
            if(b==3&&jf>=1){
                jf--;
                fang++;
                sheng-=guaig/10;
                cout<<"×ÔÉíÉúÃü"<<"-"<<guaig/10<<"="<<sheng<<endl;
                cout<<"ºÏ¼ÁÊýÁ¿"<<jf<<endl;
                cout<<"×ÔÉí·ÀÓù+1£¨"<<fang<<"£©"<<endl;
            }
            if(b==3&&jf==0) printf("ÎÞ¿ÉÓÃÒ©¼Á£¡\n"); 
        }
        if(b==4){
            if(hlf>0)cout<<"1.»ØÂÖ5000£¨·´ÉË£© ¼ÛÖµ£º100"<<endl;
            if(skf>0)cout<<"2.ʱ¿ÕÕÛµþÆ÷£¨·ÀÓùÖµ»ØÂú£© ¼ÛÖµ100"<<endl;
            if(tlf>0)cout<<"3.ħÍõµÄͷ­£¨Ï´ÎÉ˺¦ÓµÓб©»÷£© ¼ÛÖµ200"<<endl;
            b=_getch()-'0';
            if(b==1&&hlf>=1){
                hlf--;
                printf("·´µ¯É˺¦£¡");
                cout<<"×ÔÉíÉúÃü"<<"-"<<guaig/10<<"="<<sheng<<endl;
                cout<<"»ØÂÖ´ÎÊý"<<hlf<<endl;
                guais=guais-guaig;
                cout<<"¹ÖÎïÉúÃü-"<<guaig<<"="<<guais<<endl;
            }
            if(b==1&&hlf==0) printf("ÎÞ¿ÉÓ÷¨ÕÈ£¡\n"); 
            if(b==2&&skf>=1){
                skf--;
                printf("ʱ¿Õµ¹Á÷£¡");
                fangzhi=c;
                cout<<"×ÔÉí·ÀÓù´ÎÊý»Ö¸´"<<"="<<fangzhi<<endl;
                cout<<"ʱ¿ÕÊýÁ¿"<<"="<<skf<<endl;
            }
            if(b==2&&skf==0) printf("ÎÞ¿ÉÓ÷¨ÕÈ£¡\n"); 
            if(b==3&&tlf>=1){
                tlf--;
                renbao=1;
                cout<<"Ï´ι¥»÷½«»á±©»÷"<<endl;
                cout<<"ͷ­ʹÓÃÊýÁ¿"<<tlf<<endl;
            }
            if(b==3&&jf==0) printf("ÎÞ¿ÉÓ÷¨ÕÈ£¡\n"); 
        }
        if(fangzhi==0){
            printf("·ÀÓù´ÎÊýÒÑÓþ¡\n");
        }
        if(sheng<=0){
            SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
            cout<<"ÄãËÀÁË"<<endl;
            Sleep(1000);
            cout<<"ÇëÈ¥É̵겹ѪºóÔÙÕ½¶·"<<endl;
            Sleep(1000);
            cout<<"¸´»îÖÐ";
            for(int i=1;i<=5;i++){
                printf(".");
                Sleep(500);
            }
            printf("\n");
            break;
        }
    }
    }
    /*Õ½¶·º¯Êý 
    ½øÈ뺯Êý
    gonhjh£¨¹ÖÉú£¬¹Ö¹¥£¬ÉúÃü£¬¹¥»÷£¬·ÀÓù£¬»Ö¸´ÁéÒ©£¬ÊÈѪҩ¼Á£¬¸ÖÌúºÏ¼Á£¬ÉúÃüÉÏÏÞ£©
    int guais,int guaig,int sheng,int gong,int fang,int yao,int jg,int jf,int shengm)
    */ 
    int main(){/*
    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
    cout<<"ÄãÊÇһλÓÂÕߣ¬"<<endl;
    Sleep(2000);
    cout<<"ÓÐÒ»ÌìÄãÌý¼ûÁËħÍõµÄÅ­ºð£¬"<<endl;
    Sleep(2000);
    cout<<"ÓÚÊÇÄã̤ÉÏÁË´ò°ÜħÍõµÄÕ÷³Ì¡£"<<endl;
    Sleep(2500); 
    system("CLS");
    system("color F0"); 
    cout<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl;
    for(int i=0;i<=68;i++){
        printf("%c",kjl[i]);
        Sleep(90);
    }
    for(int i=0;i<=48;i++){
        printf("%c",slsf[i]);
        Sleep(90);
    }
    system("color 07"); 
    cout<<""<<endl;
    Sleep(2500); 
    system("CLS");
    printf("ÇëÉÔºó");
        for(int i=1;i<=5;i++){
            printf(".");
            Sleep(200);
        }
    printf("\n");
    int a=0,b,qian01,laotou=0;
    int qian=0,bao,muwu;
    while(a==0){
        SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY |FOREGROUND_RED |FOREGROUND_GREEN | FOREGROUND_BLUE);
        cout<<"1.ÓÂÕßÉ̵ê"<<endl; 
        cout<<"2.ÌÖ·¥Ä§Îï"<<endl;
        cout<<"3.½ÇÉ«×ÊÁÏ"<<endl;
        cout<<"ÇëÑ¡Ôñ..."<<endl;
        cout<<endl;
        b=_getch()-'0';
        if(b==1){
            system("CLS");
            SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
            printf("ÇëÉÔºó");
            for(int i=1;i<=5;i++){
                printf(".");
                Sleep(200);
                }
            printf("\n");
            cout<<"1.×°±¸"<<endl; 
            cout<<"2.Ò©Æ·"<<endl;
            cout<<"ÊäÈë0Í˳ö"<<endl;
            cout<<endl;
            b=_getch()-'0';
            if(b==1){
                system("CLS");
                while(b!=0){
                    printf("ÇëÉÔºó");
                    for(int i=1;i<=5;i++){
                        printf(".");
                        Sleep(200);
                    }
                    printf("\n");
                    cout<<"1.ÎäÆ÷"<<endl;
                    cout<<"2.¶ÜÅÆ"<<endl;
                    cout<<"3.¿ø¼×"<<endl;
                    cout<<"4.·¨ÕÈ"<<endl;
                    if(m>0)cout<<"5.Á¶»¯"<<endl;
                    cout<<"(×°±¸²»¿ÉÖظ´¹ºÂò£©"<<endl;
                    cout<<"ÊäÈë0Í˳ö"<<endl;
                    cout<<endl;
                    b=_getch()-'0';
                    if(b==1){
                        system("CLS");
                        printf("ÇëÉÔºó");
                        for(int i=1;i<=5;i++){
                            printf(".");
                            Sleep(200);
                        }
                        printf("\n");
                        cout<<"1.ÆïÊ¿³¤½££¨+10£© ¼ÛÖµ£º20"<<endl;
                        cout<<"2.ʯÖн££¨+20£© ¼ÛÖµ40"<<endl;
                        if(m>0)cout<<"3.ħÍõµÄÓÒÊÖ£¨+90£© ¼ÛÖµ150"<<endl;
                        cout<<"ÊäÈë6Í˳ö"<<endl;
                        cout<<endl;
                        b=_getch()-'0';
                        if(b==1){
                            system("CLS");
                            if(qian<20)
                                printf("½ð±Ò²»×ã\n");
                            else{
                            gong=20;
                            qian-=20;
                            cout<<"×ÔÉí¹¥»÷"<<gong<<endl;
                            }
                        }
                        if(b==2){
                            system("CLS");
                            if(qian<40)
                                printf("½ð±Ò²»×ã\n");
                            else{
                            gong=30;
                            qian-=40;
                            cout<<"×ÔÉí¹¥»÷"<<gong<<endl;
                            }
                        }
                        if(b==3&&m>0){
                            system("CLS");
                            if(qian<150)
                                printf("½ð±Ò²»×ã\n");
                            else{
                            gong=100;
                            qian-=150;
                            cout<<"×ÔÉí¹¥»÷"<<gong<<endl;
                            mo=1;
                            }
                        }
                        b=0;
                    }
                    if(b==2){
                        system("CLS");
                        printf("ÇëÉÔºó");
                        for(int i=1;i<=5;i++){
                            printf(".");
                            Sleep(200);
                        }
                        printf("\n");
                        cout<<"1.»Ê¼Ò¶ÜÅÆ£¨+10£© ¼ÛÖµ£º20"<<endl;
                        cout<<"2.ÓÀºã±¤ÀÝ£¨+20£© ¼ÛÖµ40"<<endl;
                        if(m>0)cout<<"3.ħÍõµÄ×óÊÖ£¨+90£© ¼ÛÖµ150"<<endl;
                        cout<<"ÊäÈë6Í˳ö"<<endl;
                        cout<<endl;
                        b=_getch()-'0';
                        if(b==1){
                            system("CLS");
                            if(qian<20)
                                printf("½ð±Ò²»×ã\n");
                            else{
                            fang=20;
                            qian-=20;
                            cout<<"×ÔÉí·ÀÓù"<<fang<<endl;
                            } 
    
                        }
                        if(b==2){
                            system("CLS");
                            if(qian<40)
                                printf("½ð±Ò²»×ã\n");
                            else{
                            fang=30;
                            qian-=40;
                            cout<<"×ÔÉí·ÀÓù"<<fang<<endl;
                            } 
                        }
                        if(b==3&&m>0){
                            system("CLS");
                            if(qian<150)
                                printf("½ð±Ò²»×ã\n");
                            else{
                            fang=100;
                            qian-=150;
                            cout<<"×ÔÉí·ÀÓù"<<fang<<endl;
                            mo=1;
                            } 
                        }
                    }
                    if(b==3){
                        system("CLS");
                        printf("ÇëÉÔºó");
                        for(int i=1;i<=5;i++){
                            printf(".");
                            Sleep(200);
                        }
                        printf("\n");
                        cout<<"1.Õ½Õù¿ø¼×£¨+10£© ¼ÛÖµ£º20"<<endl;
                        cout<<"2.²»ÃðÁú¼×£¨+20£© ¼ÛÖµ40"<<endl;
                        if(m>0)cout<<"3.ħÍõµÄ¾«»ª£¨+90£© ¼ÛÖµ150"<<endl;
                        cout<<"ÊäÈë6Í˳ö"<<endl;
                        cout<<endl;
                        b=_getch()-'0';
                        if(b==1){
                            system("CLS");
                            if(qian<20)
                                printf("½ð±Ò²»×ã\n");
                            else{
                            shengm=30;
                            qian-=20;
                            cout<<"×ÔÉíÉúÃüÉÏÏÞ"<<shengm<<endl;
                            }
                        }
                        if(b==2){
                            system("CLS");
                            if(qian<40)
                                printf("½ð±Ò²»×ã\n");
                            else{
                                shengm=40;
                                qian-=40;
                                cout<<"×ÔÉíÉúÃüÉÏÏÞ"<<shengm<<endl;
                            }
                        }
                        if(b==3&&qian>=150&&m>0){
                            system("CLS");
                            if(qian<150)
                                printf("½ð±Ò²»×ã\n");
                            else{
                                shengm=110;
                                qian-=150;
                                cout<<"×ÔÉíÉúÃüÉÏÏÞ"<<shengm<<endl;
                                mo=1;
                            }
                        }
                    }
                    if(b==4){
                        system("CLS");
                        printf("ÇëÉÔºó");
                        for(int i=1;i<=5;i++){
                            printf(".");
                            Sleep(200);
                        }
                        printf("\n");
                        cout<<"1.»ØÂÖ5000£¨·´ÉË£© ¼ÛÖµ£º100"<<endl;
                        cout<<"2.ʱ¿ÕÕÛµþÆ÷£¨·ÀÓùÖµ»ØÂú£© ¼ÛÖµ100"<<endl;
                        if(m>0)cout<<"3.ħÍõµÄͷ­£¨Ï´ÎÉ˺¦ÓµÓб©»÷£© ¼ÛÖµ200"<<endl;
                        cout<<"ÊäÈë6Í˳ö"<<endl;
                        cout<<endl;
                        b=_getch()-'0';
                        if(b==1){
                            system("CLS");
                            if(qian<20)
                                printf("½ð±Ò²»×ã\n");
                            else{
                                hl=1;
                                printf("¹ºÂò³É¹¦\n");
                            }
                        }
                        if(b==2){
                            system("CLS");
                            if(qian<40)
                                printf("½ð±Ò²»×ã\n");
                            else{
                                sk=1;
                                printf("¹ºÂò³É¹¦\n");
                            }
                        }
                        if(b==3&&qian>=150&&m>0){
                            system("CLS");
                            mo=1;
                            if(qian<150)
                                printf("½ð±Ò²»×ã\n");
                            else{
                                tl=1;
                                printf("¹ºÂò³É¹¦\n");
                            }
                        }
                    }
                    if(b==5&&m>0){
                        system("CLS");
                        printf("ÇëÉÔºó");
                        for(int i=1;i<=5;i++){
                            printf(".");
                            Sleep(200);
                        }
                        printf("\n");
                        cout<<"1.Á¶»¯ÎäÆ÷£¨+10£© ¼ÛÖµ50"<<endl;
                        cout<<"2.Á¶»¯¶ÜÅÆ£¨+10£© ¼ÛÖµ50"<<endl;
                        cout<<"3.Á¶»¯¿ø¼×£¨+10£© ¼ÛÖµ50"<<endl;
                        cout<<"ÊäÈë6Í˳ö"<<endl;
                        b=_getch()-'0';
                        if(b==1){
                            system("CLS");
                            if(qian<50)
                                printf("½ð±Ò²»×ã\n");
                            else{
                                gong+=10;
                                qian-=50;
                                cout<<"×ÔÉí¹¥»÷"<<gong<<endl;
                            }
                        }
                        if(b==2){
                            system("CLS");
                            if(qian<50)
                                printf("½ð±Ò²»×ã\n");
                            else{
                                fang+=10;
                                qian-=50;
                                cout<<"×ÔÉí·ÀÓù"<<fang<<endl;
                            }
                        }
                        if(b==3){
                            system("CLS");
                            if(qian<50)
                                printf("½ð±Ò²»×ã\n");
                            else{
                                shengm+=10;
                                qian-=50;
                                cout<<"×ÔÉíÉúÃüÉÏÏÞ"<<shengm<<endl;
                            }
                        }
                    } 
                }
            }
            if(b==2){
                system("CLS");
                printf("ÇëÉÔºó");
                for(int i=1;i<=5;i++){
                    printf(".");
                        Sleep(200);
                }
                printf("\n");
                cout<<"1.¿ìËٻظ´£¨»¨·Ñ1£©"<<endl;
                cout<<"2.»Ö¸´ÁéÒ©£¨»¨·Ñ5£©*5"<<endl;
                cout<<"3.ÊÈѪҩ¼Á£¨»¨·Ñ5£©*5"<<endl;
                cout<<"2.¸ÖÌúºÏ¼Á£¨»¨·Ñ5£©*5"<<endl;
                cout<<"ÊäÈë0Í˳ö"<<endl;
                cout<<endl;
                b=_getch()-'0';
                if(b==1&&qian>=1){
                    system("CLS");
                    sheng=shengm;
                    qian--;
                    cout<<"×ÔÉíÉúÃü"<<sheng<<endl;
                }
                if(b==2&&qian>=5){
                    system("CLS");
                    yao=yao+5;
                    cout<<"»Ö¸´ÁéÒ©ÊýÁ¿"<<yao<<endl;
                    qian-=5;
                }
                if(b==3&&qian>=5){
                    system("CLS");
                    jg=jg+5;
                    cout<<"ÊÈѪҩ¼ÁÊýÁ¿"<<jg<<endl;
                    qian-=5;
                }
                if(b==4&&qian>=5){
                    system("CLS");
                    jf=jf+5;
                    cout<<"¸ÖÌúºÏ¼ÁÊýÁ¿"<<jf<<endl;
                    qian-=5;
                }
            }
        }
        else if(b==2&&sheng>0){
            system("CLS");
            printf("̽Ë÷ÖÐ");
            for(int i=1;i<=5;i++){
                printf(".");
                Sleep(200); 
            }
            cout<<endl;
            o=sui(1,99);
            if(o>=1&&o<=7&&laotou==0){
                system("CLS");
                laotou=1;
                SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
                printf("ÄãÓöµ½Ò»¸ö¿´ÆðÀ´¼¢³¦ê¤ê¤µÄÀÏÍ·\n");
                Sleep(500);
                printf("ËûÎÊÄãÊÇ·ñ¿ÉÒÔ¸øËûһЩǮ\n");
                for(int i=1;i<=5;i++){
                    printf(".");
                    Sleep(200);
                }
                printf("ÇëÑ¡Ôñ\n");
                Sleep(500);
                if(qian>=5){ 
                    printf("1.¸øÓè     2.ËãÁË°É\n");
                    b=_getch()-'0';
                }
                else{ 
                    printf("1.½ð±Ò²»¹»ËãÁË°É\n");
                    b=2;
                }
                if(b==1){
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    qian-=5;
                    printf("½ð±Ò-5=%d\n",qian);
                    yao+=5;
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
                    printf("¡°Ð»Ð»Ä㣬С»ï×Ó¡£¡±\n");
                    Sleep(500);
                    printf("¡°ÕâÀïÓÐÎÒÕä²ØµÄ»Ö¸´Ò©¼Á£¬¡±\n");
                    Sleep(500);
                    printf("¡°ÎÒÒѾ­»îÁ˺ܾÃÁË£¬¡±\n");
                    Sleep(500);
                    printf("¡°¹À¼ÆÒ²Óò»ÉÏÕâ¸ö¶«Î÷ÁË¡£¡±\n");
                    Sleep(500);
                    printf("¡°ÄÃÈ¥°É¡±\n");
                    Sleep(500);
                    printf("»Ö¸´ÁéÒ©+5\n");
                    Sleep(500);
                    printf("¡°ÕâЩ¶¼ÊÇÒÔÇ°µÄÓÂÕ߸øÎҵġ±\n");
                    Sleep(500);
                    printf("¡°µ«ÊÇËûÃÇûÓÐÒ»¸öÈË»ØÀ´¡±\n");
                    Sleep(500);
                    printf("¡°Ä꼶ÇáÇáµÄ£¬Äã»ØÈ¥°É¡±\n");
                    Sleep(500);
                }
                if(b==2){
                    printf("ËûËÀÔÚÁËÄãµÄÃæÇ°\n");
                    Sleep(500);
                    printf("Á³ÉÏ»¹²ÐÁô×ŶÔÕâ¸öÊÀ½çµÄ¾øÍû\n");
                    Sleep(500);
                    printf("ËûËÀÓÚ¼¢¶öÓëÀäÄ®µÄË«ÖØ´ò»÷\n");
                    Sleep(500);
                    printf("ÄãÐÄÇéºÜ¸´ÔÓ\n");
                    Sleep(500);
                    printf("ɤ×ÓºÃÏñ±»Ò»¿é¾Þʯ¿¨×¡\n");
                    Sleep(500);
                    printf("¾«ÉñÉϵÄѹÁ¦ÈÃÄã²»ÄܺôÎü\n");
                    Sleep(500);
                    printf("Ä㻨ÁËЩǮΪËûÖðìÁËÒ»³¡¼òµ¥µÄÔáÀñ\n");
                    Sleep(500);
                    qian-=10;
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    printf("½ð±Ò-10=%d",qian);
                    Sleep(500);
                }
            }
            if(o>=8&&o<=15){
                printf("ÄãÓöµ½ÁËÒ»¸öСÄк¢\n");
                Sleep(500);
                printf("¡°¿ÉÒÔ¸øÎÒ3Æ¿¸ÖÌúºÏ¼ÁÂ𣿡±\n");
                Sleep(500);
                printf("¡°ÎªÊ²Ã´£¿£¿£¿¡±\n");
                Sleep(500);
                printf("ÎÒҪȥÏûÃðÕâÌõ·ÉϵÄÒ»¸ö¹ÖÎï\n");
                Sleep(500);
                printf("ÒªÏàÐÅËûÂð£¿\n");
                Sleep(500);
                for(int i=1;i<=5;i++){
                    printf(".");
                    Sleep(200);
                }
                printf("ÇëÑ¡Ôñ\n");
                if(jf>=3){ 
                    printf("1.¼ÓÓÍ£¡     2.ËãÁË°É\n");
                    b=_getch()-'0';
                }
                else{ 
                    printf("1.ºÏ¼Á²»¹»ËãÁË°É\n");
                    b=2;
                }
                if(b==1){
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    jf-=3;
                    printf("¸ÖÌúºÏ¼Á-3%d\n",jf);
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
                    printf("¡°Ð»Ð»£¡¡±\n");
                    Sleep(500);
                    printf("¹ýÁËÒ»»á¶ù");
                    for(int i=1;i<=5;i++){
                    printf(".");
                    Sleep(200);
                    }
                    printf("\n ¡°¸ø£¬5¸ö½ð±Ò¡±\n");
                    Sleep(500);
                    printf("¡°5¸ö½ð±Ò£¿¡±\n");
                    Sleep(500);
                    printf("ÄãÔ­±¾Ã»ÓÐÔÚÒâÕâ¸öСÄк¢.......\n");
                    Sleep(500);
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    printf("½ð±Ò+5\n");
                    qian+=5;
                    Sleep(500);
                }
                if(b==2){
                    printf("¹ýÁËÒ»»á.......\n");
                    Sleep(500);
                    printf("Ò»¸öС¹ÖÓ­Ãæ×ßÀ´\n");
                    Sleep(500);
                    printf("Ô­À´ÕâÌõ·ÉÏÕæµÄÓйÖÎï\n");
                    Sleep(500);
                    printf("µØÃæÉϺÃÏñ»¹ÓÐСÄк¢µôϵĶ«Î÷\n");
                    Sleep(500);
                    printf("ËûÓ¦¸ÃÊÇ˳ÀûÌÓÅÜÁË°É£¿\n");
                    Sleep(500);
                    system("CLS");
                    guaigs=5;
                    gongj=gong;
                    fangj=fang;
                    guais=sui(25+m*10,10);
                    c=5;
                    fangfan=10;
                    gongjh();
                    if(sheng>0){
                        SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                        qian01=qian;
                        qian=qian+sui(1,2);
                        printf("½ð±Ò+%d\n",qian-qian01);
                    }       
                    gong=gongj;
                    fang=fangj;
                    cout<<endl; 
                    b=0;
                }   
            }
            if(o>=29&&o<=36){
                printf("ÄãÓöµ½ÁËÒ»¸öÄêÇáÈË£¬\n");
                Sleep(500);
                printf("ËûµÄÁ³ÉÏÒ»Ö±´ø×Å΢Ц£¬¿´ÆðÀ´Ê®·ÖºÍÉÆ¡£\n");
                Sleep(500);
                printf("ËûÄóöÒ»¸ö²»¹æÔòÇò×´Î\n");
                Sleep(500);
                printf("˵Õâ½ÐÉÁÒ«µÄÆ«·½Èý°ËÃæÌ壬ÄÜÕÙ»½ÉñÃ÷£¬ÊµÏÖÄãÈý¸öÔ¸Íû¡£\n");
                Sleep(500);
                printf("ËûµÄÔ¸ÍûÒѾ­ÓÃÍêÁË£¬ÏÖÔÚÏëÓÃËü»»Ò»Ð©Ç®£¬ÒªÏàÐÅËûÂð£¿\n");
                Sleep(500);
                for(int i=1;i<=5;i++){
                    printf(".");
                    Sleep(200);
                }
                printf("ÇëÑ¡Ôñ\n");
                Sleep(500);
                if(qian>=50){ 
                    printf("1.¸øÓè     2.ËãÁË°É\n");
                    scanf("%d",&b);
                }
                else{ 
                    printf("1.½ð±Ò²»¹»ËãÁË°É\n");
                    b=2;
                }
                b=_getch()-'0';
                if(b==1){
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    printf("½ð±Ò-50=%d\n",qian);
                    qian-=50;
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
                    printf("Ëû¸æËßÄãÖ»Òª°ÑÕâ¸ö¶«Î÷·ÅÔÚºÚÒ¹Àï¾ÍÐÐÁË¡£\n");
                    Sleep(500);
                    printf("ÄãÏàÐÅÁËËû˵µÄ»°¡£\n");
                    Sleep(500);
                    printf("\n ÔÚÒ¹ÀÄã°ÑËü·ÅÔÚÁËÒ»¸öûÓйâÏߵĵط½\n");
                    Sleep(500);
                    printf("Ò»Ö»ÀàËÆòùòðµÄÖ×Õ͹ÖÎ»ðºìµÄ¶ÀÑÛÁѳÉÈý°êµÄÉúÎïͻȻ³öÏÖ¡£\n");
                    Sleep(500);
                    printf("Äã±»Ëû¿Ö²ÀµÄÐÎÏóÏŵ½¾«Éñ´íÂÒ£¬ÑÛÕöÕöµÄ¿´×ŵkÍ̵ôÁËÄã¡£\n");
                    Sleep(500);
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
                    cout<<"ÄãËÀÁË"<<endl;
                    Sleep(1000);
                    cout<<"ÇëÈ¥É̵겹ѪºóÔÙÕ½¶·"<<endl;
                    Sleep(1000);
                    cout<<"¸´»îÖÐ";
                    sheng=-1;
                    for(int i=1;i<=5;i++){
                        printf(".");
                        Sleep(500);
                    }
                }
                if(b==2){
                    printf("ËûËÊÁËËʼ磬\n");
                    Sleep(500);
                    printf("ʲôҲû˵£¬\n");
                    Sleep(500);
                    printf("Âõ×ųÁÖصIJ½·¥×ßÁË¡£\n");
                    Sleep(500);
                }
            }
            if(o>=20&&o<=28){
                system("CLS");
                printf("Ò»¸öСľÎÝ£¿£¿£¿\n");
                for(int i=1;i<=5;i++){
                    printf(".");
                    Sleep(200);
                }
                printf("\n½øÈ¥¿´¿´\n");
                Sleep(1000);
                muwu=sui(5,2);
                if(muwu==5){
                    system("CLS");
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED);
                    printf("ÄãµôÈëÁË´óħÍõµÄÏÝÚå\n");
                    Sleep(1000);
                    sheng=-1;
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
                    cout<<"ÄãËÀÁË"<<endl;
                    Sleep(1000);
                    cout<<"ÇëÈ¥É̵겹ѪºóÔÙÕ½¶·"<<endl;
                    Sleep(1000);
                    cout<<"¸´»îÖÐ";
                    for(int i=1;i<=5;i++){
                        printf(".");
                        Sleep(500);
                    }
                }
                if(muwu==6){
                    system("CLS");
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    qian01=qian; 
                    printf("С¹ÖµÄ²Ø±¦µã£¡£¿\n");
                    Sleep(1000);
                    qian=qian+sui(8,7);
                    printf("½ð±Ò+%d\n",qian-qian01);
                    Sleep(500);
                }
                if(muwu==7){
                    system("CLS");
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY);
                    printf("·¢ÏÖÁ˲»¿ÉÃû×´µÄµñÏñ\n");
                    Sleep(1000);
                    printf("ÄãÒòΪ¾«Éñ±ÀÀ£¶øÊÜÉËÁË\n");
                    cout<<"×ÔÉíÉúÃü"<<"-"<<5<<"="<<sheng<<endl;
                    if(sheng>=0){
                        SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
                        cout<<"ÄãËÀÁË"<<endl;
                        Sleep(1000);
                        cout<<"ÇëÈ¥É̵겹ѪºóÔÙÕ½¶·"<<endl;
                        Sleep(1000);
                        cout<<"¸´»îÖÐ";
                        for(int i=1;i<=5;i++){
                            printf(".");
                            Sleep(500); 
                        }
                    }
                }
            }
            if(o>=70&&o<=75){
                system("CLS");
                cout<<"ÄãÓöµ½ÁËÇÔ±ÒÕߣ¡"<<endl;
                printf("ÇëÉÔºó");
                for(int i=1;i<=5;i++){
                    printf(".");
                    Sleep(200);
                }
                qie=1;
                cout<<endl;
                guaigs=5;
                gongj=gong;
                fangj=fang;
                if(m==1){
                    guais=sui(105,10);
                }
                else
                    guais=sui(65,10);
                c=0;
                fangfan=10;
                gongjh();
                if(sheng>0){
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    qian01=qian;
                    qian=qian+0;
                    printf("½ð±Ò+%d\n",qian-qian01);
                    Sleep(2000);
                }
                else{
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    qian01=qian;
                    qian=qian/2;
                    printf("½ð±Ò-%d\n",qian01-qian);
                    Sleep(2000);
                }
                gong=gongj;
                fang=fangj;
                qie=0;
                cout<<endl;
            }
            if(o>=80&&o<=84){
                system("CLS");
                SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                cout<<"------ÄãÕÒµ½Á˱¦Ï䣡------"<<endl;
                printf("ÇëÉÔºó");
                for(int i=1;i<=5;i++){
                    printf(".");
                    Sleep(200);
                }
                qian01=qian;
                qian=qian+sui(8,12);
                printf("½ð±Ò+%d\n",qian-qian01);
                Sleep(2000);
            }
            printf("\n");
            system("CLS");
            SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY);
            cout<<"1.С¹Ö"<<endl;
            if(gong>=15){
                cout<<"2.ħͷ"<<endl;
                cout<<"3.»ÃÓ°"<<endl;
                if(gong>=25){
                    cout<<"4.´óħÍõ"<<endl;
                    cout<<"ÊäÈë0Í˳ö"<<endl;
                    cout<<endl;
                    b=_getch()-'0'; 
                }
                else{
                    cout<<"ÊäÈë0Í˳ö"<<endl;
                    cout<<endl;
                    b=_getch()-'0'; 
                } 
            }
            else{
                cout<<"ÊäÈë0Í˳ö"<<endl;
                cout<<endl;
                b=_getch()-'0'; 
            } 
            if(b==1){
                system("CLS");
                guaigs=5;
                gongj=gong;
                fangj=fang;
                guais=sui(25+m*10,10);
                c=5;
                fangfan=10;
                gongjh();
                if(sheng>0){
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    qian01=qian;
                    qian=qian+sui(1,2);
                    printf("½ð±Ò+%d\n",qian-qian01);
                }
                gong=gongj;
                fang=fangj;
                cout<<endl; 
                b=0;
            }
            if(b==2){
                system("CLS");
                guaigs=10;
                gongj=gong;
                fangj=fang;
                guais=sui(45+10*m,10);
                fangfan=6;
                c=7;
                gongjh();
    //              (int guais,int guaig,int sheng,int gong,int fang,int yao,int jg,int jf,int shengm,int fangfan)
                if(sheng>0){
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    qian01=qian;
                    qian=qian+sui(8,4);
                    printf("½ð±Ò+%d\n",qian-qian01);
                }
                gong=gongj;
                fang=fangj;
                cout<<endl;
                b=0;
            }
            if(b==3){
                system("CLS");
                guaigs=15;
                gongj=gong;
                fangj=fang;
                guais=sui(30+10*m,70+5*m);
                fangfan=8;
                c=7;
                gongjh();
    //              (int guais,int guaig,int sheng,int gong,int fang,int yao,int jg,int jf,int shengm,int fangfan)
                if(sheng>0){
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    qian01=qian;
                    qian=qian+sui(2,28);
                    printf("½ð±Ò+%d\n",qian-qian01);
                }
                gong=gongj;
                fang=fangj;
                cout<<endl;
                b=0;
            }
            if(b==4){
                SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED);
                gongj=gong;
                fangj=fang;
                guais=sui(95+200*m,10);
                c=10;
                fangzhi=c;
                hlf=hl;
                skf=sk;
                tlf=tl;
                while(guais>0&&sheng>0){
                    gongs=sui(gong-2,4);
                    if(renbao==1){
                        gongs*=3;
                        renbao=0;
                    }
                    guaig=sui(18+15*m,4);
                    if(bao==3){
                        guaig=guaig*3;
                        bao=0;
                    }
                    printf("\n");
                    printf("------------------------------\n");
                    printf("ħÍõÉúÃü: %d\n",guais);
                    printf("ħÍõ¹¥»÷: %d--%d\n",18+15*m,18+15*m+4);
                    printf("×¢£ºÄ§Íõ±©»÷¹æÂɲ»±ä£¡\n");
                    printf("\n------------------------------\n");
                    cout<<"1.¹¥»÷"<<endl; 
                    if(fangzhi==0) cout<<"2.·ÀÓù£¨´ÎÊý"<<fangzhi<<"£©"<<endl;
                    cout<<"3.à¾Ò©£¨ÉÁ±Ü£©"<<endl;
                    if(hlf>0||tlf>0||skf>0)cout<<"4.·¨ÕÈ"<<endl;
                    cout<<endl;
                    b=_getch()-'0'; 
                    if(b==1){
                        guais=guais-gongs;
                        sheng=sheng-guaig;
                        cout<<"¹ÖÎïÉúÃü"<<"-"<<gongs<<"="<<guais<<endl;
                        cout<<"×ÔÉíÉúÃü"<<"-"<<guaig<<"="<<sheng<<endl;
                        bao++;
                    }
                    if(b==2&&fangzhi!=0){
                        if(fang>guaig){
                            if(fang-guaig>10){
                                guais=guais-10;
                                cout<<"¹ÖÎïÉúÃü"<<"-"<<10<<"="<<guais<<endl;
                                bao++;
                            }
                            else{
                                guais=guais-fang+guaig;
                                cout<<"¹ÖÎïÉúÃü"<<"-"<<fang-guaig<<"="<<guais<<endl;
                                bao++;
                            }
                        }
                        else{
                            sheng=sheng-(guaig-fang);
                            cout<<"×ÔÉíÉúÃü"<<"-"<<guaig-fang<<"="<<sheng<<endl;
                            bao++;
                        }
                        fangzhi--;
                    }
                    if(b==3){
                        cout<<"1.»Ö¸´ÁéÒ©"<<endl; 
                        cout<<"2.ÊÈѪҩ¼Á"<<endl;
                        cout<<"3.¸ÖÌúºÏ¼Á"<<endl;
                        cin>>b;
                        if(b==1&&yao>=1){
                            yao--;
                            sheng=sheng+20;
                            if(sheng>shengm)sheng=shengm;
                            cout<<"ÁéÒ©ÊýÁ¿"<<yao<<endl;
                            cout<<"×ÔÉíÉúÃü+20£¨"<<sheng<<"£©"<<endl;
                            bao++;
                        }
                        if(b==1&&yao==0) printf("ÎÞ¿ÉÓÃÒ©¼Á£¡\n"); 
                        if(b==2&&jg>=1){
                            jg--;
                            gong++;
                            sheng-=guaig/10;
                            cout<<"×ÔÉíÉúÃü"<<"-"<<guaig/10<<"="<<sheng<<endl;
                            cout<<"Ò©¼ÁÊýÁ¿"<<jg<<endl;
                            cout<<"×ÔÉí¹¥»÷+1£¨"<<gong<<"£©"<<endl;
                            bao++;
                        }
                        if(b==2&&jg==0) printf("ÎÞ¿ÉÓÃÒ©¼Á£¡\n"); 
                        if(b==3&&jf>=1){
                            jf--;
                            fang++;
                            sheng-=guaig/10;
                            cout<<"×ÔÉíÉúÃü"<<"-"<<guaig/10<<"="<<sheng<<endl;
                            cout<<"ºÏ¼ÁÊýÁ¿"<<jf<<endl;
                            cout<<"×ÔÉí·ÀÓù+1£¨"<<fang<<"£©"<<endl;
                            bao++;
                        }
                        if(b==3&&jf==0) printf("ÎÞ¿ÉÓÃÒ©¼Á£¡\n"); 
                    }
                    if(b==4){
                        if(hlf>0)cout<<"1.»ØÂÖ5000£¨·´ÉË£© ¼ÛÖµ£º100"<<endl;
                        if(skf>0)cout<<"2.ʱ¿ÕÕÛµþÆ÷£¨·ÀÓùÖµ»ØÂú£© ¼ÛÖµ100"<<endl;
                        if(tlf>0)cout<<"3.ħÍõµÄͷ­£¨Ï´ÎÉ˺¦ÓµÓб©»÷£© ¼ÛÖµ200"<<endl;
                        cin>>b;
                        if(b==1&&hlf>=1){
                            hlf--;
                            printf("·´µ¯É˺¦£¡");
                            cout<<"×ÔÉíÉúÃü"<<"-"<<guaig/10<<"="<<sheng<<endl;
                            cout<<"»ØÂÖ´ÎÊý"<<hlf<<endl;
                            guais=guais-guaig;
                            cout<<"¹ÖÎïÉúÃü-"<<guaig<<"="<<guais<<endl;
                        }
                        if(b==1&&hlf==0) printf("ÎÞ¿ÉÓ÷¨ÕÈ£¡\n"); 
                        if(b==2&&skf>=1){
                            skf--;
                            printf("ʱ¿Õµ¹Á÷£¡");
                            fangzhi=c;
                            cout<<"×ÔÉí·ÀÓù´ÎÊý»Ö¸´"<<"="<<fangzhi<<endl;
                            cout<<"ʱ¿ÕÊýÁ¿"<<"="<<skf<<endl;
                        }
                        if(b==2&&skf==0) printf("ÎÞ¿ÉÓ÷¨ÕÈ£¡\n"); 
                        if(b==3&&tlf>=1){
                            tlf--;
                            renbao=1;
                            cout<<"Ï´ι¥»÷½«»á±©»÷"<<endl;
                            cout<<"ͷ­ʹÓÃÊýÁ¿"<<tlf<<endl;
                        }
                        if(b==3&&jf==0) printf("ÎÞ¿ÉÓ÷¨ÕÈ£¡\n"); 
                    }
                    if(sheng<=0){
                        SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
                        cout<<"ÄãËÀÁË"<<endl;
                        Sleep(1000);
                        cout<<"ÇëÈ¥É̵겹ѪºóÔÙÕ½¶·"<<endl;
                        Sleep(1000);
                        cout<<"¸´»îÖÐ";
                        for(int i=1;i<=5;i++){
                            printf(".");
                            Sleep(500);
                        }
                        printf("\n");
                        break;
                    }
                    if(fangzhi==0){
                        printf("·ÀÓù´ÎÊýÒÑÓþ¡\n"); 
                    }
                }
                if(sheng>0){
                    printf("Ä㾹Ȼ»÷°ÜÁËħÍõ£¡£¡£¡\n"); 
                    printf("¿ÉÊÇ£¬ÄãÕæµÄÓ®ÁËÂð£¿");
                    for(int i=1;i<=5;i++){
                        printf(".");
                        Sleep(800);
                    }
                    printf("\nħʯµÄÁ¦Á¿½«´ÍÓèËüÃÇÐÂÉú£¡");
                    printf("\n"); 
                    Sleep(1000);
                    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
                    qian=qian+100;
                    m++; 
                    cout<<"½ð±Ò"<<"+100"<<endl;
                    cout<<"------Äã»ñµÃÁËħʯ------"<<endl<<endl;
                }
                bao=0;
                gong=gongj;
                fang=fangj;
                cout<<endl; 
            }
        }
        else if(b==2&&sheng<=0){
            SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_BLUE);
            cout<<"ÄãËÀÁË"<<endl;
            cout<<"ÇëÈ¥É̵겹ѪºóÔÙÕ½¶·"<<endl<<endl;
        }
        else if(b==3){
            system("CLS");
            SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_GREEN |FOREGROUND_BLUE);
            printf("ÇëÉÔºó");
            for(int i=1;i<=5;i++){
                printf(".");
                Sleep(500);
            }
            printf("\n");
            printf("\n×ÔÉí×ÊÁÏ\n");
            printf("----------------------------------------------\n");
            printf("ÉúÃü: %d                   ",sheng);
            printf("¹¥»÷: %d\n\n",gong);
            printf("·ÀÓù: %d                   ",fang);
            printf("ÉúÃüÉÏÏÞ: %d\n\n",shengm);
            printf("½ð±Ò: %d                   ",qian);
            printf("»Ö¸´ÁéÒ©: %d\n\n",yao);
            printf("ÊÈѪҩ¼Á: %d                   ",jg);
            printf("¸ÖÌúºÏ¼Á: %d\n\n",jf);
            if(m>0) printf("ħʯ: %d                   ",m);
            printf("\n----------------------------------------------\n");
            cout<<endl<<endl;
        }
        if(m==5){
            if(mo==1){
                system("CLS");
                SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED);
                Sleep(2000);
                cout<<"ÄãµÚÎå´Î»÷°ÜÁËħÍõ£¬"<<endl;
                Sleep(2000);
                cout<<"¿´×ÅÑÛǰûÔÙ¸´»îµÄħÍõµÄʬÌ壬"<<endl;
                Sleep(2000);
                cout<<"¡°½áÊøÁË£¿¡±"<<endl;
                Sleep(2000);
                cout<<"Äã¿´×ÅÈÔÔÚÉ¢·¢×Å×ÏÉ«¹ââµÄħʯ£¬"<<endl;
                Sleep(2000);
                cout<<"°µ×Ô·ñ¶¨ÁËÕâ¸öÎÊÌâ¡£"<<endl;
                Sleep(2000);
                cout<<"ÄãµÄÊÓÏß²»¾­Òâ¼äɨ¹ýÄã´ÓħÍõÉíÉÏ»ñµÃµÄÕ½ÀûÆ·£¬"<<endl;
                Sleep(2000);
                cout<<"È´·¢ÏÖËüÃÇËƺõºÍÄãµÄÉíÌåÈÚºÏÔÚÁËÒ»Æð¡£"<<endl;
                Sleep(2000);
                cout<<"¡°Ôõô»ØÊ£¿£¡¡±"<<endl;
                Sleep(2000);
                cout<<"ÄãÑÛÇ°µÄ¾°ÎïÖð½¥±äµÃÄ£ºý."<<endl;
                Sleep(2000);
                cout<<"ÄãµÄÑÛ¾¦É¢·¢×Å×ÏÉ«µÄ¹îÒìµÄ¹ââ¡£"<<endl;
                Sleep(2000);
                cout<<"Òâʶģºý¼ä£¬Äã¿´µ½Ò»¸ö»ÃÓ°³öÏÖÔÚÄãÃæÇ°¡£"<<endl;
                Sleep(2000);
                cout<<"ËüÊÕ×ßÁËËÄ¿éħʯ£¬°Ñ×îºóÒ»¿é·ÅÔÚÁËÄãµÄÐØÇ°¡£"<<endl;
                Sleep(2000);
                cout<<"¡°Ô­À´...Èç´Ë...¡±"<<endl;
                Sleep(2000);
                cout<<"Ò»ÉùÅ­ºð»Øµ´ÔÚɽ¹ÈÖ®¼ä¡£"<<endl;
                Sleep(2000);
                cout<<"......"<<endl;
                Sleep(2000);
                cout<<"Ò»¸öеÄÉíÓ°³öÏÖ£¬"<<endl;
                Sleep(2000);
                cout<<"¡°Ä§Íõ£¬ÎÒÀ´ÌÖ·¥ÄãÁË£¡¡±"<<endl;
                Sleep(2000);
                break; 
            }
            else{
                system("CLS");
                SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN); 
                cout<<"²Êµ°½á¾Ö£¡£¡£¡£¡£¡"<<endl;
                SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED);
                Sleep(2000);
                cout<<"ÄãµÚÎå´Î»÷°ÜÁËħÍõ£¬"<<endl;
                Sleep(2000);
                cout<<"¿´×ÅÑÛǰûÔÙ¸´»îµÄħÍõµÄʬÌ壬"<<endl;
                Sleep(2000);
                cout<<"¡°½áÊøÁË£¿¡±"<<endl;
                Sleep(2000);
                cout<<"Äã¿´×ÅÈÔÔÚÉ¢·¢×Å×ÏÉ«¹ââµÄħʯ£¬"<<endl;
                Sleep(2000);
                cout<<"°µ×Ô·ñ¶¨ÁËÕâ¸öÎÊÌâ¡£"<<endl;
                Sleep(2000);
                cout<<"ÄãµÄÊÓÏß²»¾­Òâ¼äɨ¹ýÄãÄãµÄÉíÌ壬"<<endl;
                Sleep(2000);
                cout<<"È´·¢ÏÖÄãµÄÉíÌåÔÚÖð½¥±äµÃ͸Ã÷¡£"<<endl;
                Sleep(2000);
                cout<<"¡°Ôõô»ØÊ£¿£¡¡±"<<endl;
                Sleep(2000);
                cout<<"ÄãµÄ¶ú±ß»Øµ´Æ𲻿ÉÃû×´µÄÊÂÎïµÄµÍÓï¡£"<<endl;
                Sleep(2000);
                cout<<"ÄãµÄ´óÄÔÏÝÈëÁË·è¿ñ¡£"<<endl;
                Sleep(2000);
                cout<<"Äã¿´µ½Ò»¸ö»ÃÓ°³öÏÖÔÚÌì±ß£¬²¢ÇÒÔÚÂýÂýµØÏûʧ¡£"<<endl;
                Sleep(2000);
                cout<<"ÄãµÄÉñÇéͻȻ±äµÃ¼á¶¨¶øÓÖ·è¿ñ¡£"<<endl;
                Sleep(2000);
                cout<<"¡°×ñÃü...ÎÒµÄÖ÷ÈË...¡±"<<endl;
                Sleep(2000);
                cout<<"......"<<endl;
                Sleep(2000);
                cout<<"Ò»¸öеÄÉíÓ°³öÏÖ£¬"<<endl;
                Sleep(2000);
                cout<<"¡°Ä§Íõ£¬ÎÒÀ´ÌÖ·¥ÄãÁË£¡¡±"<<endl;
                Sleep(2000);
                break;
            }
        }
    }
    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), FOREGROUND_INTENSITY | FOREGROUND_RED |FOREGROUND_GREEN);
    cout<<endl; 
    cout<<"---------------------------------------------------------";
    cout<<"Íê½á";
    cout<<"---------------------------------------------------------"<<endl;
    Sleep(2000);
    cout<<"¸ÐлÓÎÍæ";*/
        int a,b;
        cin>>a>>b;
        cout<<a+b;
        return 0;
    }
    
  • 0
    @ 2023-09-15 18:00:59

    #include <bits/stdc++.h>
    using namespace std;
    int main()
    {
    long long a,b,c;
    cin>>a>>b;
    c=a+b;
    printf ("%d",c);
    }

  • 0
    @ 2023-08-28 16:43:23
    #incude<iostream>
    using namespace std;
    int main(){
        int a, b;
        cin >> a >> b;
        cout << a + b;
        return 0;
    }
    
  • 0
    @ 2023-08-23 14:29:32
    #include<bits/stdc++.h>
    using namespace std;
    int main(){
        long long a,b;
        cin>>a>>b;
        cout<<a+b;
        return 0;
    }
    
  • 0
    @ 2023-08-20 16:04:30
    #include <iostream>
    using namespace std;
    int main(){
        int x,y;
        cin>>x>>y;
        cout<<x+y;
        return 0;
    }
    
  • 0
    @ 2023-05-26 17:02:17

    让评测姬爆炸的代码

    #include<bits/stdc++.h>
    using namespace std;
    long long a[32768][32768];
    int main(){
        int x,y;
        cin>>x>>y;
        for(int i=1;i<=32767;i++)
            for(int j=1;j<=32767;j++)
                a[i][j] = i+j;
        cout<<a[x][y];
        return 0;
    }
    
  • 0
    @ 2022-07-16 22:18:36

    / Vijos / 题库 / A+B Problem /
    题解

    1284 条题解
    神-董 (董由) LV 7
    发表您的题解
    Wylker LV 8 @ 4 年前
    告诉你们什么叫做暴力的题解。

    #include<bits/stdc++.h>
    #define gou int main()
    #define li {
    #define guo int a,b;
    #define jia cin>>a>>b;
    #define sheng cout<<a+b;
    #define si return 0;
    #define yi }
    using namespace std;
    gou
    li
    guo
    jia
    sheng
    si
    yi
    Louisssss @ 4 年前
    #include<bits/stdc++.h>
    #define qi int main()
    #define yin
    {
    #define huo int a,b;
    #define fu cin>>a>>b;
    #define bi cout<<a+b;
    #define qu return 0;
    #define zhi
    }
    using namespace std;
    qi
    yin
    huo
    fu
    bi
    qu
    zhi

    neway5 @ 3 年前
    学习了

    zrmpaul @ 2 年前
    zzmg,jbl(

    crystal_clear @ 10 个月前
    你是秀儿

    kunker @ 4 个月前
    @Louisssss: 太秀了

    huyifei323 LV 4 @ 10 个月前
    本题直接用 int 就能过。
    完整代码:

    #include<iostream> //引入 iostream 头文件
    using namespace std; //使用 std 命名空间
    int main(){ //主函数,程序从这里开始
    int a,b; //定义两个变量,一个叫 a ,一个叫 b
    cin>>a>>b; //输入
    cout<<a+b; //输出他们的和
    return 0; //主函数应返回 0
    }
    讲解:
    - iostream 头文件也叫输入输出流,是 C++ 特有的头文件,用来输入和输出。
    - std 命名空间是 C++ 的标准命名空间,输入输出就定义在这里面。
    - int main() 函数是程序的开始,一个程序必须有他。
    - int a,b 是定义了两个 int 型变量,aa 和 bb。
    - cin>>a>>b 是在输入 aa 和 bb。
    - cout<<a+b 是在输出 a+ba+b。
    - return 0 是 int main() 函数的返回值,这个返回值必须是 00 ,不然会 RE。

    管理员大大求通过
    看在我写得这么认真的情况下,就给我点个赞吧

    zhangzhengyan LV 4 @ 3 周前
    #include<bits/stdc++.h>
    using namespace std;
    signed main(){
    int a,b;
    cin>>a>>b;
    cout<<a+b;
    }
    lxylluvio LV 4 @ 1 个月前
    来一篇好玩的题解。

    #include <bits/stdc++.h>

    #define _ using
    #define __ namespace
    #define ___ std;
    #define ____ int
    #define _____ main() {
    #define ______ int a, b;
    #define _______ cin >> a >> b;
    #define ________ cout << a + b << '\n';
    #define _________ }



    ______ _______ ________ _________

    FXT1110011010OI LV 4 @ 2 个月前
    基础语法

    //头文件
    #include <iostream>
    #include <cstring>
    #include <algorithm>
    #include <cstdio>
    #include <cmath>
    //命名空间
    using namespace std;

    //主函数
    int main()
    {
    int x, y; //定义x,y
    //int类型,用"%d"输出
    scanf("%d%d", &x, &y); //输入x,y
    printf("%d", x + y); //输出x + y
    return 0;
    }
    cby LV 7 @ 2 个月前
    暴力解题之进阶版

    #include <iterator>
    #include <functional>
    #include<vector>
    #include<deque>
    #include<list>
    #include<queue>
    #include<stack>
    #include<set>
    #include<map>
    #include<algorithm>
    #include<numeric>
    #include<memory>
    #include<utility>
    #define gou int main()
    #define li {
    #define guo int a,b;
    #define jia cin>>a>>b;
    #define sheng cout<<a+b;
    #define si return 0;
    #define yi }
    using namespace std;
    gou
    li
    guo
    jia
    sheng
    si
    yi

    ZYX_pi LV 6 @ 4 个月前
    #include<iostream>//头文件
    using namespace std;//命名空间
    int main()//主函数
    {
    int a,b;//定义变量a b
    cin>>a>>b;//输入变量a b
    cout<<a+b<<endl;//输出a与b的和
    return 0;//返回值
    }
    ZYX_pi LV 6 @ 4 个月前
    #include<iostream>
    using namespace std;
    int main()
    {
    int a,b;
    cin>>a>>b;
    cout<<a+b<<endl;
    return 0;
    }

    ZYX_pi LV 6 @ 4 个月前
    #include<iostream>
    using namespace std;
    int main()
    {
    int a,b;
    cin>>a>>b;
    cout<<a+b<<endl;
    return 0;
    }

    tommyfj LV 4 @ 4 个月前
    最基础的A+B解法(给蒟蒻看的)

    #include <iostream>//头文件很重要
    using namespace std;
    int main()//主函数
    {
    int a,b,c;//定义三个变量a,b,c
    cin >> a >> b;//输入a,b值
    c = a+b;//求和并存入c中
    cout << c;//输出c
    return 0;
    }

    点个赞再走呗,跪谢!ヾ(≧▽≦*)o

    GalaxyOier LV 4 @ 9 个月前
    #include<bits/stdc++.h>//万能头
    using namespace std;

    int main()//主函数
    {
    int a,b;//定义
    cin>>a>>b;//输入
    cout<<a+b;//输出
    return 0;
    }
    黄青玲 LV 7 @ 9 个月前
    额,注意不要选错语言,不然这是入门题,零基础人不调试也能过。

    #include <iostream>
    using namespace std;
    int main(){
    int a,b;
    cin>>a>>b;
    cout<<a+b;
    return 0;
    }
    qq913653500 LV 10 @ 4 年前
    #include <iostream>
    using namespace std;
    int main()
    {
    int a,b;
    cin>>a>>b;
    cout<<a+b;
    return 0;
    }
    神-董 (董由) LV 7 @ 10 秒前

    / Vijos / 题库 / A+B Problem /
    题解

    1283 条题解
    神-董 (董由) LV 7
    发表您的题解
    Wylker LV 8 @ 4 年前
    告诉你们什么叫做暴力的题解。

    #include<bits/stdc++.h>
    #define gou int main()
    #define li {
    #define guo int a,b;
    #define jia cin>>a>>b;
    #define sheng cout<<a+b;
    #define si return 0;
    #define yi }
    using namespace std;
    gou
    li
    guo
    jia
    sheng
    si
    yi
    Louisssss @ 4 年前
    #include<bits/stdc++.h>
    #define qi int main()
    #define yin
    {
    #define huo int a,b;
    #define fu cin>>a>>b;
    #define bi cout<<a+b;
    #define qu return 0;
    #define zhi
    }
    using namespace std;
    qi
    yin
    huo
    fu
    bi
    qu
    zhi

    neway5 @ 3 年前
    学习了

    zrmpaul @ 2 年前
    zzmg,jbl(

    crystal_clear @ 10 个月前
    你是秀儿

    kunker @ 4 个月前
    @Louisssss: 太秀了

    huyifei323 LV 4 @ 10 个月前
    本题直接用 int 就能过。
    完整代码:

    #include<iostream> //引入 iostream 头文件
    using namespace std; //使用 std 命名空间
    int main(){ //主函数,程序从这里开始
    int a,b; //定义两个变量,一个叫 a ,一个叫 b
    cin>>a>>b; //输入
    cout<<a+b; //输出他们的和
    return 0; //主函数应返回 0
    }
    讲解:
    - iostream 头文件也叫输入输出流,是 C++ 特有的头文件,用来输入和输出。
    - std 命名空间是 C++ 的标准命名空间,输入输出就定义在这里面。
    - int main() 函数是程序的开始,一个程序必须有他。
    - int a,b 是定义了两个 int 型变量,aa 和 bb。
    - cin>>a>>b 是在输入 aa 和 bb。
    - cout<<a+b 是在输出 a+ba+b。
    - return 0 是 int main() 函数的返回值,这个返回值必须是 00 ,不然会 RE。

    管理员大大求通过
    看在我写得这么认真的情况下,就给我点个赞吧

    zhangzhengyan LV 4 @ 3 周前
    #include<bits/stdc++.h>
    using namespace std;
    signed main(){
    int a,b;
    cin>>a>>b;
    cout<<a+b;
    }
    lxylluvio LV 4 @ 1 个月前
    来一篇好玩的题解。

    #include <bits/stdc++.h>

    #define _ using
    #define __ namespace
    #define ___ std;
    #define ____ int
    #define _____ main() {
    #define ______ int a, b;
    #define _______ cin >> a >> b;
    #define ________ cout << a + b << '\n';
    #define _________ }


    FXT1110011010OI LV 4 @ 2 个月前
    基础语法

    //头文件
    #include <iostream>
    #include <cstring>
    #include <algorithm>
    #include <cstdio>
    #include <cmath>
    //命名空间
    using namespace std;

    //主函数
    int main()
    {
    int x, y; //定义x,y
    //int类型,用"%d"输出
    scanf("%d%d", &x, &y); //输入x,y
    printf("%d", x + y); //输出x + y
    return 0;
    }
    cby LV 7 @ 2 个月前
    暴力解题之进阶版

    #include <iterator>
    #include <functional>
    #include<vector>
    #include<deque>
    #include<list>
    #include<queue>
    #include<stack>
    #include<set>
    #include<map>
    #include<algorithm>
    #include<numeric>
    #include<memory>
    #include<utility>
    #define gou int main()
    #define li {
    #define guo int a,b;
    #define jia cin>>a>>b;
    #define sheng cout<<a+b;
    #define si return 0;
    #define yi }
    using namespace std;
    gou
    li
    guo
    jia
    sheng
    si
    yi

    ZYX_pi LV 6 @ 4 个月前
    #include<iostream>//头文件
    using namespace std;//命名空间
    int main()//主函数
    {
    int a,b;//定义变量a b
    cin>>a>>b;//输入变量a b
    cout<<a+b<<endl;//输出a与b的和
    return 0;//返回值
    }
    ZYX_pi LV 6 @ 4 个月前
    #include<iostream>
    using namespace std;
    int main()
    {
    int a,b;
    cin>>a>>b;
    cout<<a+b<<endl;
    return 0;
    }

    ZYX_pi LV 6 @ 4 个月前
    #include<iostream>
    using namespace std;
    int main()
    {
    int a,b;
    cin>>a>>b;
    cout<<a+b<<endl;
    return 0;
    }

    tommyfj LV 4 @ 4 个月前
    最基础的A+B解法(给蒟蒻看的)

    #include <iostream>//头文件很重要
    using namespace std;
    int main()//主函数
    {
    int a,b,c;//定义三个变量a,b,c
    cin >> a >> b;//输入a,b值
    c = a+b;//求和并存入c中
    cout << c;//输出c
    return 0;
    }

    点个赞再走呗,跪谢!ヾ(≧▽≦*)o

    GalaxyOier LV 4 @ 9 个月前
    #include<bits/stdc++.h>//万能头
    using namespace std;

    int main()//主函数
    {
    int a,b;//定义
    cin>>a>>b;//输入
    cout<<a+b;//输出
    return 0;
    }
    黄青玲 LV 7 @ 9 个月前
    额,注意不要选错语言,不然这是入门题,零基础人不调试也能过。

    #include <iostream>
    using namespace std;
    int main(){
    int a,b;
    cin>>a>>b;
    cout<<a+b;
    return 0;
    }
    qq913653500 LV 10 @ 4 年前
    #include <iostream>
    using namespace std;
    int main()
    {
    int a,b;
    cin>>a>>b;
    cout<<a+b;
    return 0;
    }
    神-董 (董由) LV 7 @ 15 秒前

    迷雾通公司注册在爱沙尼亚,受欧盟严格的隐私法保护。我们从不会记录您的浏览信息,也绝不会向第三方主动交出任何用户资料。
    更重要的是,我们即使被黑客入侵或受外力胁迫,也无法出卖我们的用户。我们使用先进的密码学算法开发了Mizaru用户认证协议。这独特的技术保证用户和浏览记录之间没有任何联系。
    市场上没有任何其他翻墙软件提供迷雾通给您的私密性。
    我们极其重视您的隐私。我们不会,并且根本不能监视您的浏览记录。迷雾通的代码更是全部开源的。

    难以封锁
    迷雾通不仅仅针对已有的封锁技术。我们使用最前沿的反封锁技术,不管是现在还是未来的封锁系统都难以屏蔽迷雾通。
    迷雾通更是目前市面上唯一为一切付费用户提供服务保证的翻墙软件。迷雾通被封杀几天,我们就赔款几天!

    实惠、简单
    我们视网络自由和隐私为基本权利。所以我们提供完全免费的中速浏览,够浏览新闻、查邮件、看标清视频等。超快速度的付费Plus账号仅需€5/月。
    不管您用Windows、Mac、Linux、还是Android,安装使用迷雾通并不繁琐。一键就可连接自由的互联网。

    永远的天狼星 LV 6 @ 2 个月前
    本小弟第一次发题解
    #include <iostream>
    using namespace std;
    int main(){
    long long a,b;//注意,不开long long见祖宗
    cin>>a>>b;
    cout<<a+b;//很水
    }

    November (CLH_W) LV 10 @ 3 个月前

    #include<bits/stdc++.h>
    using namespace std;
    int n,m;
    int main(){
    cin>>n>>m;
    cout<<n+m;
    return 0;
    }

    zqj LV 3 @ 3 个月前
    import java.util.Scanner;
    public class qiuhe {

    public static void main(String[] args) {
    int x,y,n;
    Scanner sc=new Scanner(System.in);
    System.out.println("请输入x的值:");
    x=sc.nextInt();
    System.out.println("请输入y的值:");
    y=sc.nextInt();
    n=x+y;
    System.out.println("它们的和为:"+n);
    }

    }

    xwvrn9m1u LV 4 @ 3 个月前
    #include<iostream>
    #include<cstring>
    #include<cstdio>
    #include<cstring>
    using namespace std;
    struct node
    {
    int data,rev,sum;
    node *son[2],*pre;
    bool judge();
    bool isroot();
    void pushdown();
    void update();
    void setson(node *child,int lr);
    }lct[233];
    int top,a,b;
    node *getnew(int x)
    {
    node *now=lct+ ++top;
    now->data=x;
    now->pre=now->son[1]=now->son[0]=lct;
    now->sum=0;
    now->rev=0;
    return now;
    }
    bool node::judge(){return pre->son[1]==this;}
    bool node::isroot()
    {
    if(pre==lct)return true;
    return !(pre->son[1]==this||pre->son[0]==this);
    }
    void node::pushdown()
    {
    if(this==lct||!rev)return;
    swap(son[0],son[1]);
    son[0]->rev^=1;
    son[1]->rev^=1;
    rev=0;
    }
    void node::update(){sum=son[1]->sum+son[0]->sum+data;}
    void node::setson(node *child,int lr)
    {
    this->pushdown();
    child->pre=this;
    son[lr]=child;
    this->update();
    }
    void rotate(node *now)
    {
    node *father=now->pre,*grandfa=father->pre;
    if(!father->isroot()) grandfa->pushdown();
    father->pushdown();now->pushdown();
    int lr=now->judge();
    father->setson(now->son[lr^1],lr);
    if(father->isroot()) now->pre=grandfa;
    else grandfa->setson(now,father->judge());
    now->setson(father,lr^1);
    father->update();now->update();
    if(grandfa!=lct) grandfa->update();
    }
    void splay(node *now)
    {
    if(now->isroot())return;
    for(;!now->isroot();rotate(now))
    if(!now->pre->isroot())
    now->judge()==now->pre->judge()?rotate(now->pre):rotate(now);
    }
    node *access(node *now)
    {
    node *last=lct;
    for(;now!=lct;last=now,now=now->pre)
    {
    splay(now);
    now->setson(last,1);
    }
    return last;
    }
    void changeroot(node *now)
    {
    access(now)->rev^=1;
    splay(now);
    }
    void connect(node *x,node *y)
    {
    changeroot(x);
    x->pre=y;
    access(x);
    }
    void cut(node *x,node *y)
    {
    changeroot(x);
    access(y);
    splay(x);
    x->pushdown();
    x->son[1]=y->pre=lct;
    x->update();
    }
    int query(node *x,node *y)
    {
    changeroot(x);
    node *now=access(y);
    return now->sum;
    }
    int main()
    {
    scanf("%d%d",&a,&b);
    node *A=getnew(a);
    node *B=getnew(b);
    //连边 Link
    connect(A,B);
    //断边 Cut
    cut(A,B);
    //再连边orz Link again
    connect(A,B);
    printf("%d\n",query(A,B));
    return 0;
    }

    xwvrn9m1u LV 4 @ 3 个月前
    计算就完了谁不会谁可以不用学了

    kunker LV 4 @ 4 个月前
    #include <bits/stdc++.h>
    using namespace std;

    int main()
    {
    long long a, b;

    scanf("%d %d", &a, &b);

    printf("%d", a + b);

    return 0;
    }

    1 2 3 4 5

    A+B Problem
    查看题目
    递交
    讨论
    题解
    信息
    ID
    1000
    递交
    Accepted
    通过消息
    flag{1+1=2}
    难度
    9
    分类
    (无)
    标签
    (无)
    递交数
    71475
    我的递交数
    1
    已通过
    27517
    通过率
    38%
    被复制
    141
    状态
    开发
    支持
    关于 联系我们 隐私 服务条款 版权申诉 Language
    © 2005 - 2021 Vijos.org uibuild-f24a75e-10-gf0efbad-dirty 沪ICP备14040537号-1

    神-董 (董由) LV 7 @ 32 秒前

    迷雾通公司注册在爱沙尼亚,受欧盟严格的隐私法保护。我们从不会记录您的浏览信息,也绝不会向第三方主动交出任何用户资料。
    更重要的是,我们即使被黑客入侵或受外力胁迫,也无法出卖我们的用户。我们使用先进的密码学算法开发了Mizaru用户认证协议。这独特的技术保证用户和浏览记录之间没有任何联系。
    市场上没有任何其他翻墙软件提供迷雾通给您的私密性。
    我们极其重视您的隐私。我们不会,并且根本不能监视您的浏览记录。迷雾通的代码更是全部开源的。

    难以封锁
    迷雾通不仅仅针对已有的封锁技术。我们使用最前沿的反封锁技术,不管是现在还是未来的封锁系统都难以屏蔽迷雾通。
    迷雾通更是目前市面上唯一为一切付费用户提供服务保证的翻墙软件。迷雾通被封杀几天,我们就赔款几天!

    实惠、简单
    我们视网络自由和隐私为基本权利。所以我们提供完全免费的中速浏览,够浏览新闻、查邮件、看标清视频等。超快速度的付费Plus账号仅需€5/月。
    不管您用Windows、Mac、Linux、还是Android,安装使用迷雾通并不繁琐。一键就可连接自由的互联网。

    永远的天狼星 LV 6 @ 2 个月前
    本小弟第一次发题解
    #include <iostream>
    using namespace std;
    int main(){
    long long a,b;//注意,不开long long见祖宗
    cin>>a>>b;
    cout<<a+b;//很水
    }

    November (CLH_W) LV 10 @ 3 个月前

    #include<bits/stdc++.h>
    using namespace std;
    int n,m;
    int main(){
    cin>>n>>m;
    cout<<n+m;
    return 0;
    }

    zqj LV 3 @ 3 个月前
    import java.util.Scanner;
    public class qiuhe {

    public static void main(String[] args) {
    int x,y,n;
    Scanner sc=new Scanner(System.in);
    System.out.println("请输入x的值:");
    x=sc.nextInt();
    System.out.println("请输入y的值:");
    y=sc.nextInt();
    n=x+y;
    System.out.println("它们的和为:"+n);
    }

    }

    xwvrn9m1u LV 4 @ 3 个月前
    #include<iostream>
    #include<cstring>
    #include<cstdio>
    #include<cstring>
    using namespace std;
    struct node
    {
    int data,rev,sum;
    node *son[2],*pre;
    bool judge();
    bool isroot();
    void pushdown();
    void update();
    void setson(node *child,int lr);
    }lct[233];
    int top,a,b;
    node *getnew(int x)
    {
    node *now=lct+ ++top;
    now->data=x;
    now->pre=now->son[1]=now->son[0]=lct;
    now->sum=0;
    now->rev=0;
    return now;
    }
    bool node::judge(){return pre->son[1]==this;}
    bool node::isroot()
    {
    if(pre==lct)return true;
    return !(pre->son[1]==this||pre->son[0]==this);
    }
    void node::pushdown()
    {
    if(this==lct||!rev)return;
    swap(son[0],son[1]);
    son[0]->rev^=1;
    son[1]->rev^=1;
    rev=0;
    }
    void node::update(){sum=son[1]->sum+son[0]->sum+data;}
    void node::setson(node *child,int lr)
    {
    this->pushdown();
    child->pre=this;
    son[lr]=child;
    this->update();
    }
    void rotate(node *now)
    {
    node *father=now->pre,*grandfa=father->pre;
    if(!father->isroot()) grandfa->pushdown();
    father->pushdown();now->pushdown();
    int lr=now->judge();
    father->setson(now->son[lr^1],lr);
    if(father->isroot()) now->pre=grandfa;
    else grandfa->setson(now,father->judge());
    now->setson(father,lr^1);
    father->update();now->update();
    if(grandfa!=lct) grandfa->update();
    }
    void splay(node *now)
    {
    if(now->isroot())return;
    for(;!now->isroot();rotate(now))
    if(!now->pre->isroot())
    now->judge()==now->pre->judge()?rotate(now->pre):rotate(now);
    }
    node *access(node *now)
    {
    node *last=lct;
    for(;now!=lct;last=now,now=now->pre)
    {
    splay(now);
    now->setson(last,1);
    }
    return last;
    }
    void changeroot(node *now)
    {
    access(now)->rev^=1;
    splay(now);
    }
    void connect(node *x,node *y)
    {
    changeroot(x);
    x->pre=y;
    access(x);
    }
    void cut(node *x,node *y)
    {
    changeroot(x);
    access(y);
    splay(x);
    x->pushdown();
    x->son[1]=y->pre=lct;
    x->update();
    }
    int query(node *x,node *y)
    {
    changeroot(x);
    node *now=access(y);
    return now->sum;
    }
    int main()
    {
    scanf("%d%d",&a,&b);
    node *A=getnew(a);
    node *B=getnew(b);
    //连边 Link
    connect(A,B);
    //断边 Cut
    cut(A,B);
    //再连边orz Link again
    connect(A,B);
    printf("%d\n",query(A,B));
    return 0;
    }

    xwvrn9m1u LV 4 @ 3 个月前
    计算就完了谁不会谁可以不用学了

    1 2 3 4 5

    A+B Problem
    查看题目
    递交
    讨论
    题解
    信息
    ID
    1000
    递交
    Accepted
    通过消息
    flag{1+1=2}
    难度
    9
    分类
    (无)
    标签
    (无)
    递交数
    71475
    我的递交数
    1
    已通过
    27517
    通过率
    38%
    被复制
    141
    状态
    开发
    支持
    关于 联系我们 隐私 服务条款 版权申诉 Language
    © 2005 - 2021 Vijos.org uibuild-f24a75e-10-gf0efbad-dirty 沪ICP备14040537号-1

  • 0
    @ 2022-07-16 22:17:47

    迷雾通公司注册在爱沙尼亚,受欧盟严格的隐私法保护。我们从不会记录您的浏览信息,也绝不会向第三方主动交出任何用户资料。
    更重要的是,我们即使被黑客入侵或受外力胁迫,也无法出卖我们的用户。我们使用先进的密码学算法开发了Mizaru用户认证协议。这独特的技术保证用户和浏览记录之间没有任何联系。
    市场上没有任何其他翻墙软件提供迷雾通给您的私密性。
    我们极其重视您的隐私。我们不会,并且根本不能监视您的浏览记录。迷雾通的代码更是全部开源的。

    难以封锁

    迷雾通不仅仅针对已有的封锁技术。我们使用最前沿的反封锁技术,不管是现在还是未来的封锁系统都难以屏蔽迷雾通。
    迷雾通更是目前市面上唯一为一切付费用户提供服务保证的翻墙软件。迷雾通被封杀几天,我们就赔款几天!

    实惠、简单

    我们视网络自由和隐私为基本权利。所以我们提供完全免费的中速浏览,够浏览新闻、查邮件、看标清视频等。超快速度的付费Plus账号仅需€5/月。
    不管您用Windows、Mac、Linux、还是Android,安装使用迷雾通并不繁琐。一键就可连接自由的互联网。

信息

ID
1000
难度
9
分类
(无)
标签
(无)
递交数
73466
已通过
28179
通过率
38%
被复制
198