The program is very primitive. All notes have the same length. Write your melody and play it.
I hope, this simple program can inspire somebody to study JavaScript and music synthesis. Best wishes, Egor Maximenko.
The program is based on a very small and powerful library RIFFWAVE.js v0.03 (Copyleft 2011 by Pedro Ladaria).
The source of this page contains less than 400 lines of JavaScript code (mouse right click, View Page Source).
Supported browsers: Firefox and Safari.