# Yellow submarine
# Sonic Pi versie van het nummer van John Lennon en Paul McCartney

use_bpm 120

3.times do
  
  # [1] In the town where I was born
  # [2] And he told us of his life
  # [3] And we lived beneath the waves
  
  play :B3, release: 0.75
  sleep 0.75
  play :C4
  sleep 0.25
  play :D4, amp: 0.5, sustain: 1.25
  sleep 2.75
  play :B3
  sleep 0.25
  play :A3, release: 0.75
  sleep 0.75
  play :B3
  sleep 0.25
  play :G3, release: 3
  sleep 3
  
  # [1] Lived a man who sailed to see
  # [2] In the land of submarines
  # [3] In our yellow submarime
  
  play :B3, release: 0.75
  sleep 0.75
  play :B3
  sleep 0.25
  play :A3, release: 0.75
  sleep 0.75
  play :G3
  sleep 0.25
  play :E3, release: 1 + 0.75
  sleep 1.75
  play :E3
  sleep 0.25
  play :B3, release: 0.75
  sleep 0.75
  play :B3
  sleep 0.25
  play :A3, release: 3
  sleep 3
end

# REFREIN
2.times do
  # dit is de laatste tel van het couplet
  # en ook van de eerste repetitie van het refrein
  sleep 1
  
  # We all live in a
  play :D4, release: 0.75
  sleep 1
  play :D4, release: 0.75
  sleep 1
  play :D4, release: 0.75
  sleep 1
  play :D4, release: 0.5
  sleep 0.75
  play :E4, release: 0.25
  sleep 0.25
  
  # yellow submarine
  2.times do
    play :A3
    sleep 0.75
    play :A3
    sleep 0.25
    play :A3
    sleep 0.75
    play :A3
    sleep 0.25
    play :A3
    sleep 1.5
  end
  
  # yellow submarine
  play :G3
  sleep 0.75
  play :G3
  sleep 0.25
  play :G3
  sleep 0.75
  play :G3
  sleep 0.25
  play :G3
  sleep 1
end
