int crotchet=100; //negra
int minim=*crotchet; //blanca
int semibreve=4*crotchet/2; //redonda
int quaver=crotchet/4; //corchera
int semiQualver=crotchet/4; //semicorchera
int demiSemiQuaver=crotchet/8; //fusa
int crotchetWithPoint= crotchet+quaver;
int minimWithPoint=minim+crotchet;
int crotchetSilence=crotchet;
int minimSilence=minim;
const int semiBreveSilence=SemiBreve;
const int quaverSilence=quaver;
const int semiquaverSilence=Semiquaver;
const long DO=523,25;
const long RE=587,33;
const long MI=659,26;
const long FA=698,46;
const long SOL=783,99;
const long LA=880;
const long SI=987,77;
const long PAU=30000; //pausa
cosnt int speakerOut=8; //pin
const int nextNote=200; //siguiente nota
const int nextBlock=300;
const int elements=341;
void setup(){
pinMode(speackerOut,output);}
void loop(){
int melody[]={MI,PAU,MI,MI,MI,PAU,MI,PAU,MI,FA,PAU,SOL,FA,PAU,MO,PAU,MI,FA,MI,FA,PAU,SOL,FA,PAU,MI,PAU,MI,FA,MI,FA,PAU,SOL,PAU,SOL};
int duration[]={crotchetWithPoint,nextNote,quaver,crotchet, crotchet, nextNote, crotchet, nextBlock,...crotchet};
for(int i=0;note(elements;note++){
tone(speackerOut, melody[note];
delay(duration[note]);
notone(speackerOut);}}