问题标题: 小白船

0
1
已解决
熊智晖
熊智晖
高级天翼
高级天翼

#include <iostream>
#include <cstdio>
#include <cstdlib>
#include <windows.h>
using namespace std;
// _在前表示低音, 在后表示高音
// o表示升
const int _oC=277,_oD=311,_oF=370,_oG=415,_oA=466;
const int _C=262,_D=294,_E=330,_F=349,_G=392,_A=440,_B=494;
const int oC=554,oD=622,oF=740,oG=831,oA=932;
const int C=523,D=578,E=659,F=698,G=784,A=880,B=988;
const int C_=1047,D_ =1175,E_=1319,F_=1397,G_=1568,A_=1760,B_=1976;
const int oC_=1109,oD_=1245,oF_=1480,oG_=1661,oA_=1865;
const int T=300; //一拍的长度
const int Stop=150; //一拍休止符的长度
int main(){
    cout<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl<<endl;
    cout<<"                            请收听:小白船!";
    Sleep(1000);
    while(1){
        system("cls");
        system("color 9F");
        cout<<endl<<endl;
        cout<<"            ▆▆▆   "<<endl;
        cout<<"          █████     "<<endl;
        cout<<"              ▊ "<<endl;
        cout<<"      ▎▎    ▊ "<<endl;
        cout<<"       ●     ▊ "<<endl;
        cout<<"     ▂██▁ ▊     "<<endl;
        cout<<"  ████████████"<<endl;
        cout<<"      ████████"<<endl; 
        cout<<"                            蓝蓝的天空银河里";
        Beep(G,T*2);
        Beep(A,T);
        Beep(A,T);
        Sleep(10);
        Beep(G,T*2);
        Beep(E,T);
        Beep(G,T*2);
        Sleep(10);
        Beep(D,T);
        Beep(_G,T*2);
        Sleep(500);
        
        system("cls");
        system("color 9F");
        cout<<endl<<endl;
        cout<<"             ▆▆▆   "<<endl;
        cout<<"           █████     "<<endl;
        cout<<"               ▊ "<<endl;
        cout<<"       ▎▎    ▊ "<<endl;
        cout<<"        ●     ▊ "<<endl;
        cout<<"      ▂██▁ ▊     "<<endl;
        cout<<"   ████████████"<<endl;
        cout<<"       ████████"<<endl; 
        cout<<"                            有只小白船";
        Beep(_A,T*2);
        Beep(C,T);
        Beep(D,T*2);
        Sleep(10);
        Beep(G,T);
        Beep(E,T*2);
        Sleep(1000);
        
        system("cls");
        system("color 9F");
        cout<<endl<<endl;
        cout<<"              ▆▆▆   "<<endl;
        cout<<"            █████     "<<endl;
        cout<<"                ▊ "<<endl;
        cout<<"        ▎▎    ▊ "<<endl;
        cout<<"         ●     ▊ "<<endl;
        cout<<"       ▂██▁ ▊     "<<endl;
        cout<<"    ████████████"<<endl;
        cout<<"        ████████"<<endl; 
        cout<<"                            船上有棵桂花树";
        Beep(G,T*2);
        Beep(A,T);
        Sleep(10);
        Beep(G,T*2);
        Beep(E,T);
        Beep(G,T*2);
        Sleep(10);
        Beep(D,T);
        Beep(_G,T*2);
        Sleep(500);
        
        system("cls");
        system("color 9F");
        cout<<endl<<endl;
        cout<<"            ▆▆▆   "<<endl;
        cout<<"          █████     "<<endl;
        cout<<"              ▊ "<<endl;
        cout<<"      ▎▎    ▊ "<<endl;
        cout<<"       ●     ▊ "<<endl;
        cout<<"     ▂██▁ ▊     "<<endl;
        cout<<"  ████████████"<<endl;
        cout<<"      ████████"<<endl; 
        cout<<"                            白兔在游玩";
        Beep(_A,T*2);
        Beep(C,T);
        Beep(_G,T*2);
        Sleep(10);
        Beep(D,T);
        Beep(C,T*2);
        Sleep(1000);
        
        system("cls");
        system("color 9F");
        cout<<endl<<endl;
        cout<<"            ▆▆▆   "<<endl;
        cout<<"          █████     "<<endl;
        cout<<"              ▊ "<<endl;
        cout<<"      ▎▎    ▊ "<<endl;
        cout<<"       ●     ▊ "<<endl;
        cout<<"     ▂██▁ ▊     "<<endl;
        cout<<"  ████████████"<<endl;
        cout<<"      ████████"<<endl; 
        cout<<"                            桨儿桨儿看不见";
        Beep(E,T*2);
        Beep(E,T);
        Sleep(10);
        Beep(E,T*2);
        Beep(D,T);
        Beep(E,T*2);
        Sleep(10);
        Beep(A,T);
        Beep(G,T*2);
        Sleep(500);
        
        system("cls");
        system("color 9F");
        cout<<endl<<endl;
        cout<<"            ▆▆▆   "<<endl;
        cout<<"          █████     "<<endl;
        cout<<"              ▊ "<<endl;
        cout<<"      ▎▎    ▊ "<<endl;
        cout<<"       ●     ▊ "<<endl;
        cout<<"     ▂██▁ ▊     "<<endl;
        cout<<"  ████████████"<<endl;
        cout<<"      ████████"<<endl; 
        cout<<"                            船上也没帆";
        Beep(E,T*2);
        Beep(D,T);
        Beep(E,T*2);
        Sleep(10);
        Beep(A,T);
        Beep(G,T*2);
        Sleep(1000);
        
        system("cls");
        system("color 9F");
        cout<<endl<<endl;
        cout<<"            ▆▆▆   "<<endl;
        cout<<"          █████     "<<endl;
        cout<<"              ▊ "<<endl;
        cout<<"      ▎▎    ▊ "<<endl;
        cout<<"       ●     ▊ "<<endl;
        cout<<"     ▂██▁ ▊     "<<endl;
        cout<<"  ████████████"<<endl;
        cout<<"      ████████"<<endl; 
        cout<<"                            飘呀飘呀";
        Beep(C_,T*2);
        Beep(G,T*2);
        Beep(E,T);
        Sleep(10);
        Beep(G,T); 
        Beep(A,T*2);
        Sleep(500);
        
        system("cls");
        system("color 9F");
        cout<<endl<<endl;
        cout<<"            ▆▆▆   "<<endl;
        cout<<"          █████     "<<endl;
        cout<<"              ▊ "<<endl;
        cout<<"      ▎▎    ▊ "<<endl;
        cout<<"       ●     ▊ "<<endl;
        cout<<"     ▂██▁ ▊     "<<endl;
        cout<<"  ████████████"<<endl;
        cout<<"      ████████"<<endl; 
        cout<<"                            飘向西天";
        Beep(G,T*2);
        Beep(D,T);
        Beep(_G,T*2);
        Sleep(10);
        Beep(D,T);
        Beep(C,T*2);
        Sleep(2000);
    }
    return 0;
}


0
已采纳
小鸡咕咕叫15856960106
小鸡咕咕叫15856960106
高级守护
高级守护

看上去不错!

0
0
王泽轩
王泽轩
资深天翼
资深天翼

emmmm...........................................

0
朱小川
朱小川
缔造者
缔造者

或者再加一首歌,《让我们荡起双桨》

0
0
0
0
0
0
0
吕梓瑜
吕梓瑜
初级天翼
初级天翼

这音乐怪怪的,没有那个音调,但还是很不错哒!!!(我不行)

0
0
我要回答