音乐代码 (DNF天空之城、欢乐颂)。

太感人了 DNF天空之城

#include <cstdio>
#include <windows.h>
#define    qdo 262 
#define qre 294
#define qmi 330        //q前缀为低音,1后缀为高音,s前缀为半音阶 
#define qfa 349
#define qso 392
#define qla 440
#define qsi 494
#define do 523
#define re 578
#define mi 659
#define fa 698
#define so 784
#define la 880
#define si 988
#define do1 1046
#define re1 1175
#define mi1 1318
#define fa1 1480
#define so1 1568
#define la1 1760
#define si1 1976
#define sqdo 277
#define sqre 311
#define sqfa 370
#define sqso 415
#define sqla 466
#define sdo 554
#define sre 622
#define sfa 740
#define sso 831
#define sla 932
#define sdo1 1046
#define sre1 1245
#define sfa1 1480
#define sso1 1661
#define sla1 1865

int main()
{
int pai=400,ban=200;
int ting=128;

Sleep(1000);

Beep(la,ban);
Beep(si,ban);
Sleep(ting);

Beep(do1,pai+ban);
Beep(si,ban);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);
Beep(mi1,pai);
Sleep(ting);

Beep(si,3*pai);
Sleep(ting);
Beep(mi,ban);
Beep(mi,ban);

Beep(la,ban+pai);
Beep(so,ban);
Sleep(ting);
Beep(la,pai);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);

Beep(so,2*pai);
Sleep(ting);
Sleep(pai);
Beep(mi,ban);
Sleep(ting/2);
Beep(mi,ban);
Sleep(ting/2);

Beep(fa,pai+ban);
Beep(mi,ban);
Sleep(ting);
Beep(fa,ban);
Beep(do1,ban+pai);
Sleep(ting);

Beep(mi,2*pai);
Sleep(ting);
Sleep(ban);
Beep(do1,ban);
Sleep(ting/2);
Beep(do1,ban);
Sleep(ting/2);
Beep(do1,ban);
Sleep(ting/2);

Beep(si,ban+pai);
Beep(sfa,ban);
Sleep(ting);
Beep(sfa,pai);
Beep(si,pai);
Sleep(ting);

Beep(si,2*pai);
Sleep(ting);
Sleep(pai);
Beep(la,ban);
Beep(si,ban);
Sleep(ting);

Beep(do1,pai+ban);
Beep(si,ban);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);
Beep(mi1,pai);
Sleep(ting);

Beep(si,2*pai);
Sleep(ting);
Sleep(pai);
Beep(mi,ban);
Sleep(20);
Beep(mi,ban);
Sleep(ting);

Beep(la,pai+ban);
Beep(so,ban);
Sleep(ting);
Beep(la,pai);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);

Beep(so,3*pai);
Sleep(ting+ban);
Beep(mi,ban);
Sleep(ting/2);

Beep(fa,pai);
Sleep(ting);
Beep(do1,ban);
Beep(si,ban);
Sleep(20);
Beep(si,pai);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);

Beep(re1,ban);
Sleep(20);
Beep(re1,ban);
Sleep(20);
Beep(mi1,ban);
Sleep(ting/2);
Beep(do1,pai);
Sleep(ting+pai);

Beep(do1,pai);
Beep(si,ban);
Sleep(ting);
Beep(la,ban);
Sleep(20);
Beep(la,ban);
Sleep(ting);
Beep(si,pai);
Sleep(ting);
Beep(sso,pai);
Sleep(ting);

Beep(sso,2*pai);
Sleep(ting+pai);
Beep(do1,ban);
Beep(re1,ban);
Sleep(ting);

Beep(mi1,pai+ban);
Beep(re1,ban);
Sleep(ting);
Beep(mi1,pai);
Sleep(ting);
Beep(fa1,pai);
Sleep(ting);

Beep(re1,2*pai);
Sleep(pai+ting);
Beep(so,ban);
Sleep(20);
Beep(so,ban);
Sleep(ting);

Beep(do1,ban);
Beep(si,ban);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);
Beep(mi1,pai);
Sleep(ting);

Beep(mi1,2*pai);
Sleep(ting+2*pai);

Beep(la,ban);
Beep(si,ban);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);
Beep(si,pai);
Sleep(ting);
Beep(re1,ban);
Sleep(20);
Beep(re1,ban);
Sleep(ting);

Beep(do1,pai+ban);
Beep(so,ban);
Sleep(20);
Beep(so,pai);
Sleep(pai+ting);

Beep(fa1,pai);
Sleep(ting);
Beep(mi1,pai);
Sleep(ting);
Beep(re1,pai);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);

Beep(mi1,4*pai);

Beep(mi1,pai*2);
Sleep(pai+ting);
Beep(mi1,pai);
Sleep(ting);

Beep(la1,2*pai);
Sleep(ting);
Beep(so1,pai);
Sleep(ting);
Beep(so1,pai);
Sleep(ting);

Beep(mi1,ban);
Sleep(ting/2);
Beep(re1,ban);
Sleep(ting);
Beep(do1,pai);
Sleep(ting+ban);
Beep(do1,ban);
Sleep(ting);

Beep(re1,pai);
Sleep(ting);
Beep(do1,ban);
Beep(re1,ban);
Sleep(20);
Beep(re1,ban);
Sleep(ting);
Beep(so1,pai);
Sleep(ting);

Beep(mi1,2*pai);
Sleep(ting+pai);
Beep(mi,pai);
Sleep(ting);

Beep(la1,2*pai);
Sleep(ting);
Beep(so1,2*pai);
Sleep(ting);

Beep(mi1,ban);
Beep(re1,ban);
Sleep(ting);
Beep(do1,2*pai);
Sleep(ting+ban);
Beep(do1,ban);
Sleep(ting);

Beep(re1,pai);
Sleep(ting);
Beep(do1,ban);
Beep(re1,ban);
Sleep(20);
Beep(re1,ban);
Sleep(ting);
Beep(si,pai);
Sleep(ting);

Beep(la,2*pai);
Sleep(ting);
Beep(la,ban);
Beep(si,ban);

Beep(do1,pai+ban);
Beep(si,ban);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);
Beep(mi1,pai);
Sleep(ting);

Beep(si,3*pai);
Sleep(ting);
Beep(mi,ban);
Beep(mi,ban);

Beep(la,ban+pai);
Beep(so,ban);
Sleep(ting);
Beep(la,pai);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);

Beep(so,2*pai);
Sleep(ting);
Sleep(pai);
Beep(mi,ban);
Sleep(ting/2);
Beep(mi,ban);
Sleep(ting/2);

Beep(fa,pai+ban);
Beep(mi,ban);
Sleep(ting);
Beep(fa,ban);
Beep(do1,ban+pai);
Sleep(ting);

Beep(mi,2*pai);
Sleep(ting);
Sleep(ban);
Beep(do1,ban);
Sleep(ting/2);
Beep(do1,ban);
Sleep(ting/2);
Beep(do1,ban);
Sleep(ting/2);

Beep(si,ban+pai);
Beep(sfa,ban);
Sleep(ting);
Beep(sfa,pai);
Beep(si,pai);
Sleep(ting);

Beep(si,2*pai);
Sleep(ting);
Sleep(pai);
Beep(la,ban);
Beep(si,ban);
Sleep(ting);

Beep(do1,pai+ban);
Beep(si,ban);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);
Beep(mi1,pai);
Sleep(ting);

Beep(si,2*pai);
Sleep(ting);
Sleep(pai);
Beep(mi,ban);
Sleep(20);
Beep(mi,ban);
Sleep(ting);

Beep(la,pai+ban);
Beep(so,ban);
Sleep(ting);
Beep(la,pai);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);

Beep(so,3*pai);
Sleep(ting+ban);
Beep(mi,ban);
Sleep(ting/2);

Beep(fa,pai);
Sleep(ting);
Beep(do1,ban);
Beep(si,ban);
Sleep(20);
Beep(si,pai);
Sleep(ting);
Beep(do1,pai);
Sleep(ting);

Beep(re1,ban);
Sleep(20);
Beep(re1,ban);
Sleep(20);
Beep(mi1,ban);
Sleep(ting/2);
Beep(do1,pai);
Sleep(ting+pai);

Beep(la,4*pai);

Sleep(1000);
main();

}

欢乐颂 

#include <cstdio>
#include<iostream>
#include <windows.h>
using namespace std;

#define    qdo 262 
#define qre 294
#define qmi 330        //q前缀为低音,1后缀为高音,s前缀为半音阶 
#define qfa 349
#define qso 392
#define qla 440
#define qsi 494
#define do 523
#define re 578
#define mi 659
#define fa 698
#define so 784
#define la 880
#define si 988
#define do1 1046
#define re1 1175
#define mi1 1318
#define fa1 1480
#define so1 1568
#define la1 1760
#define si1 1976
#define sqdo 277
#define sqre 311
#define sqfa 370
#define sqso 415
#define sqla 466
#define sdo 554
#define sre 622
#define sfa 740
#define sso 831
#define sla 932
#define sdo1 1046
#define sre1 1245
#define sfa1 1480
#define sso1 1661
#define sla1 1865
int t=0;
int main()
{
    int bk=500;
    Sleep(1000);
    while (1==1)
    {
        cout<<"*"<<++t<<endl;
    Beep(mi,bk);
    Beep(mi,bk);
    Beep(fa,bk);
    Beep(so,bk);Beep(so,bk);
    Beep(fa,bk);Beep(mi,bk);
    Beep(re,bk);Beep(do,bk);
    Beep(do,bk);Beep(re,bk);
    Beep(mi,bk);Beep(mi,bk+250);
    Beep(re,bk-250);Beep(re,bk*2);
    
    Beep(mi,bk);
    Beep(mi,bk);
    Beep(fa,bk);
    Beep(so,bk);Beep(so,bk);
    Beep(fa,bk);Beep(mi,bk);
    Beep(re,bk);Beep(do,bk);
    Beep(do,bk);Beep(re,bk);
    Beep(mi,bk);Beep(re,bk+250);
    Beep(do,bk-250);Beep(do,bk*2);
    
    Beep(re,bk);
    Beep(re,bk);
    Beep(mi,bk);
    Beep(do,bk);
    Beep(re,bk);
    Beep(mi,bk-250);Beep(fa,bk-250);
    Beep(mi,bk);
    Beep(do,bk);
    Beep(re,bk);
    Beep(mi,bk-250); Beep(fa,bk-250);
    Beep(mi,bk);
    Beep(re,bk);
    Beep(do,bk);
    Beep(re,bk);
    Beep(qso,bk*2);
    
    Beep(mi,bk);
    Beep(mi,bk);
    Beep(fa,bk);
    Beep(so,bk);Beep(so,bk);
    Beep(fa,bk);Beep(mi,bk);
    Beep(re,bk);Beep(do,bk);
    Beep(do,bk);Beep(re,bk);
    Beep(mi,bk);Beep(re,bk+250);
    Beep(do,bk-250);Beep(do,bk*2);
    }
    return 0;
}

 

 车万之血.

#include <cstdio>
#include<windows.h>
using namespace std;
const
int do1=262;
int re1=294;
int mi1=330;
int fa1=349;
int so1=392;
int la1=440;
int si1=494;
int do2=523;
int re2=578;
int mi2=659;
int fa2=698;
int so2=784;
int la2=880;
int si2=988;
int do3=1046;
int re3=1175;
int mi3=1318;
int fa3=1400;
int so3=1568;
int la3=1760;
int si3=1976;
int do4=2090;
int sdo1=277;
int sre1=311;
int sfa1=370;
int sso1=415;
int sla1=466;
int sdo2=554;
int sre2=622;
int sfa2=740;
int sso2=831;
int sla2=932;
int sdo3=1046;
int sre3=1245;
int sfa3=1480;
int sso3=1661;
int sla3=1865;
int main() {
    Beep(la2,300);
    Beep(mi3,100);
    Beep(re3,100);
    Beep(mi3,300);
    Beep(la2,300);
    Beep(la2,300);
    Beep(mi3,100);
    Beep(re3,100);
    Beep(mi3,300);
    Beep(la2,300);
    Beep(la2,300);
    Beep(mi3,100);
    Beep(re3,100);
    Beep(mi3,300);
    Beep(la2,300);
    Beep(sso2,300);
    Beep(la2,300);
    Beep(si2,300);
    Beep(re3,300);
    Beep(la2,300);
    Beep(mi3,100);
    Beep(re3,100);
    Beep(mi3,300);
    Beep(la2,300);
    Beep(la2,300);
    Beep(mi3,100);
    Beep(re3,100);
    Beep(mi3,300);
    Beep(la2,300);
    Beep(la2,300);
    Beep(mi3,100);
    Beep(re3,100);
    Beep(mi3,300);
    Beep(la2,300);
    Beep(sso2,600);
    Beep(mi3,300);
    Beep(do4,100);
    Beep(si3,100);
    Beep(do4,100);
    Sleep(200);
    Beep(mi3,300);
    Beep(mi3,300);
    Beep(do4,100);
    Beep(si3,100);
    Beep(do4,100);
    Sleep(200);
    Beep(mi3,300);
    Beep(mi3,300);
    Beep(do4,100);
    Beep(si3,100);
    Beep(do4,100);
    Sleep(200);
    Beep(mi3,300);
    Beep(re3,300);
    Beep(mi3,300);
    Beep(sso3,300);
    Beep(si3,300);
    Beep(mi3,300);
    Beep(do4,100);
    Beep(si3,100);
    Beep(do4,100);
    Sleep(200);
    Beep(mi3,300);
    Beep(mi3,300);
    Beep(do4,100);
    Beep(si3,100);
    Beep(do4,100);
    Sleep(200);
    Beep(mi3,300);
    Beep(mi3,300);
    Beep(do4,100);
    Beep(si3,100);
    Beep(do4,100);
    Sleep(200);
    Beep(mi3,300);
    Beep(sso2,600);
    Beep(si2,100);
    Beep(do3,100);
    Beep(re3,100);
    Beep(so3,100);
    Beep(re3,100);
    Beep(si2,100);
    Beep(la2,900);
    Beep(mi3,600);
    Beep(re3,300);
    Beep(mi3,300);
    Beep(la2,900);
    Beep(mi3,600);
    Beep(re3,300);
    Beep(mi3,300);
    Beep(la2,900);
    Beep(mi3,600);
    Beep(re3,300);
    Beep(mi3,300);
    Beep(so3,150);
    Beep(la2,900);
    Beep(mi3,600);
    Beep(re3,300);
    Beep(mi3,300);
    Beep(la2,900);
    Beep(mi3,600);
    Beep(re3,300);
    Beep(mi3,300);
    Beep(la2,900);
    Beep(mi3,600);
    Beep(re3,300);
    Beep(mi3,300);
    Beep(so3,150);
    Beep(fa3,600);
    Beep(fa3,300);
    Beep(so3,450);
    Beep(fa3,300);
    Beep(mi3,900);
    Beep(re3,450);
    Beep(do3,450);
    Beep(re3,600);
    Beep(mi3,600);
    Beep(si2,450);
    Beep(do3,600);
    Beep(la2,600);
    Beep(mi3,450);
    Beep(fa3,900);
    Beep(fa3,300);
    Beep(so3,450);
    Beep(fa3,300);
    Beep(mi3,600);
    Beep(la3,450);
    Beep(mi3,600);
    Beep(fa3,600);
    Beep(so3,600);
    Beep(la3,600);
    Beep(si3,600);
    Beep(do4,600);
    return 0;
}

 

posted @ 2017-01-24 08:20  杀猪状元  阅读(1660)  评论(0编辑  收藏  举报