Just a piano music nothing much

use_bpm 80

define the chords

chord1 = chord(:C3, :minor)
chord2 = chord(:A3, :minor)
chord3 = chord(:D3, :minor)
chord4 = chord(:G3, :minor)

define the melody notes

notes = [:C4, :B3, :A3, :G3, :F3, :E3, :D3]

play the chords and melody in a sad sequence

4.times do
play_pattern_timed chord1, 1
sleep 0.5
play_pattern_timed notes, 0.25
play_pattern_timed chord2, 1
sleep 0.5
play_pattern_timed notes.reverse, 0.25
play_pattern_timed chord3, 1
sleep 0.5
play_pattern_timed notes, 0.25
play_pattern_timed chord4, 1
sleep 0.5
play_pattern_timed notes.reverse, 0.25
end

Hi Kuntal. Welcome to in-thread Nice first piece. You might like to put your code inside three reverse ticks ```
on the line before the code and another three on the line after. That way it is easier for users to copy the code directly to their Sonic Pi. I show it below, with # symbols before the lines describing your code.
I also tried a different synth. There’s so much experimenting and fun you can have with Sonic Pi

use_bpm 80
use_synth :tri

#define the chords
chord1 = chord(:C3, :minor)
chord2 = chord(:A3, :minor)
chord3 = chord(:D3, :minor)
chord4 = chord(:G3, :minor)

#define the melody notes
notes = [:C4, :B3, :A3, :G3, :F3, :E3, :D3]

#play the chords and melody in a sad sequence
4.times do
  play_pattern_timed chord1, 1
  sleep 0.5
  play_pattern_timed notes, 0.25
  play_pattern_timed chord2, 1
  sleep 0.5
  play_pattern_timed notes.reverse, 0.25
  play_pattern_timed chord3, 1
  sleep 0.5
  play_pattern_timed notes, 0.25
  play_pattern_timed chord4, 1
  sleep 0.5
  play_pattern_timed notes.reverse, 0.25
end