All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > General > Cryptography
A Song for the Season 2 (Posted on 2007-12-25) Difficulty: 3 of 5
Taking pictures on the fourth at 4:45
Having leftover turkey on the first at 4:45
Eating extra stuffing on the twenty third at 45:29
Yelling for more lights on the eleventh at 47:89
Adding some icing to cookies on the fourteenth at 45:29
Redecorating the tree on the first at 42:46
Eating some gingerbread cookies on the fifth at 14:59
Frolicking in the snow on the twenty third at 13:07

Opening some letters from family on the eighteenth at 45:76
Using lights around the house on the fourth at 27:36
Naming your favorite songs to sing on the twenty first at 12:24
Decorating the tree with ornaments on the first at 58:35
Adding eyes to the gingerbread on the seventh at 14:59
Reading some stories on the first at 20:73
Opening some cards on the ninth at 14:59
Using the pans for spice cake on the twentieth at 4:45

Naming reindeer as you sing on the first at 48:13
Drinking eggnog along with family on the second at 12:24
Having a great time with your family on the thirteenth at 3:04
Eating pumpkin pie at the dinner table on the ninth at 16:24
Roasting some chestnuts on the tenth at 20:73
Eating some candy canes on the fourth at 3:04
Singing favorite songs on the second at 39:90
Opening gifts on the seventh at 27:36
Making your favorite cherry pie on the first at 43:33

Eating some apple pie on the sixth at 40:04
Watching favorite movies on the fifth at 54:80
Having family visit on the first at 27:36
Eating roast lamb on the tenth at 12:24
Receiving warm welcomes on the fourth at 47:27
Eating cookies on the fourth at 45:51

See The Solution Submitted by Gamer    
No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
Hints/Tips re(4): An observation -- hint -- picking nits | Comment 10 of 11 |
(In reply to re(3): An observation -- hint by Gamer)

Having peeked at the answer, and having had no success identifying the song from the notes given, I looked into one of my wife's Christmas song books and wrote the notes.  The staff indicated that B's and F's were flatted, which my wife tells me means the piece is written for the key of B flat:


The capital letters are quarter notes and the lower case eighth notes. (Actually a couple of the capitals are dotted quarter notes, but it's not noticeable, especially as in one case a dotted quarter note should have been tied to another quarter note.) The F was the lowest note in the octave used (all the F's).

The first part of the following program plays this, and it's recognizable this time.

The second part transposes it so that the F that starts every verse is translated down to a C. I haven't bothered to put octave notations in, as I had done in the first part so that the tune would be recognizable (the computer treats an octave as beginning with A, but I had to change that to F for the playing of the first part, as that was the lowest note; it would be different for the transposed version, which has C low).

DIM n$(12)
DATA c,cd,d,de,e,f,fg,g,ga,a,ab,b
FOR i = 1 TO 12: READ n$(i): PRINT n$(i); " "; : NEXT

DATA fDacbgFgF
DATA fgabbcdCC
DATA fDacbgFgF

' play the original
FOR i = 1 TO 4
 READ vs$
 FOR j = 1 TO LEN(vs$)
  c$ = MID$(vs$, j, 1)
  cc$ = c$
  IF LCASE$(cc$) = "b" OR LCASE$(cc$) = "e" THEN c$ = c$ + "-"
  IF cc$ = UCASE$(cc$) THEN c$ = "l4" + c$:  ELSE c$ = "l8" + c$
  IF LCASE$(cc$) >= "f" THEN c$ = "<" + c$ + ">"
  PLAY c$: PRINT c$;

RESTORE theMusic
' transpose F down to C (5 halftones)
FOR i = 1 TO 4
 READ vs$
 FOR j = 1 TO LEN(vs$)
  c$ = MID$(vs$, j, 1)
  cc$ = LCASE$(c$)
  FOR ix = 1 TO 12
    IF n$(ix) = cc$ THEN EXIT FOR
  IF cc$ = "b" OR cc$ = "e" THEN ix = ix - 1
  ix = ix - 5
  IF ix < 1 THEN ix = ix + 12
  cc$ = n$(ix)
  IF cc$ = "fg" THEN cc$ = "f#"
  IF c$ = UCASE$(c$) THEN cc$ = UCASE$(cc$)
  PRINT cc$; " ";

The transposed version, beginning each verse with a low C (not just the first and third verses), comes out as follows:

c A e g f d C d C
c d e f f g a G G
c A e g f d C d C
c D d e d c F F

Again, capital means quarter note and lower case eighth note. All the C's are the low end of the scale, as were all the F's in the songbook.

compare to

c a g g d c d c
c d e f f g a g
c a e a f d c d c
c d d e c f

The editing of this comment corrects the previous version in which the transposition did not take into consideration the flat nature of B's and E's in the original. That correction was made by adding the program line

IF cc$ = "b" OR cc$ = "e" THEN ix = ix - 1

Edited on December 30, 2007, 10:58 pm

Edited on December 30, 2007, 11:20 pm
  Posted by Charlie on 2007-12-30 22:53:24

Please log in:
Remember me:
Sign up! | Forgot password

Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (3)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Copyright © 2002 - 2018 by Animus Pactum Consulting. All rights reserved. Privacy Information