You have a limited number of notes, but those notes can be arranged however you like to create any melody within your note limitations. I’m fairly certain that you can’t utilize the same note multiple times in one melody though.