How would I go about defining two separate variables where one can be mapped onto the other to produce some typical output? For instance:

durations = {
  4 8 8 2
pitches = {
  e' g' f' a'
\score {
  ...something goes here...

To get something like this:

e'4 g'8 f'8 a'2 in LilyPond

1 Answer 1


There is a popular snippet to do exactly this, https://lsr.di.unimi.it/LSR/Item?id=654

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.