#!/usr/bin/perl use 5.36.0; use MIDI::Simple; use Music::VoiceGen; my $voice = Music::VoiceGen->new( pitches => [qw/60 62 64 65 67 69/], intervals => [qw/1 2 3 4 5 7 -1 -2 -3 -4 -5/], ); for ( 1 .. 16 ) { my $n = $voice->rand; print $n, " "; n qn => $n; } print "\n"; write_score 'markov.midi';