|
| 1 | +# Instructions |
| 2 | + |
| 3 | +Generate the lyrics of the song 'I Know an Old Lady Who Swallowed a Fly'. |
| 4 | + |
| 5 | +While you could copy/paste the lyrics, or read them from a file, this problem is much more interesting if you approach it algorithmically. |
| 6 | + |
| 7 | +This is a [cumulative song][cumulative-song] of unknown origin. |
| 8 | + |
| 9 | +This is one of many common variants. |
| 10 | + |
| 11 | +```text |
| 12 | +I know an old lady who swallowed a fly. |
| 13 | +I don't know why she swallowed the fly. Perhaps she'll die. |
| 14 | +
|
| 15 | +I know an old lady who swallowed a spider. |
| 16 | +It wriggled and jiggled and tickled inside her. |
| 17 | +She swallowed the spider to catch the fly. |
| 18 | +I don't know why she swallowed the fly. Perhaps she'll die. |
| 19 | +
|
| 20 | +I know an old lady who swallowed a bird. |
| 21 | +How absurd to swallow a bird! |
| 22 | +She swallowed the bird to catch the spider that wriggled and jiggled and tickled inside her. |
| 23 | +She swallowed the spider to catch the fly. |
| 24 | +I don't know why she swallowed the fly. Perhaps she'll die. |
| 25 | +
|
| 26 | +I know an old lady who swallowed a cat. |
| 27 | +Imagine that, to swallow a cat! |
| 28 | +She swallowed the cat to catch the bird. |
| 29 | +She swallowed the bird to catch the spider that wriggled and jiggled and tickled inside her. |
| 30 | +She swallowed the spider to catch the fly. |
| 31 | +I don't know why she swallowed the fly. Perhaps she'll die. |
| 32 | +
|
| 33 | +I know an old lady who swallowed a dog. |
| 34 | +What a hog, to swallow a dog! |
| 35 | +She swallowed the dog to catch the cat. |
| 36 | +She swallowed the cat to catch the bird. |
| 37 | +She swallowed the bird to catch the spider that wriggled and jiggled and tickled inside her. |
| 38 | +She swallowed the spider to catch the fly. |
| 39 | +I don't know why she swallowed the fly. Perhaps she'll die. |
| 40 | +
|
| 41 | +I know an old lady who swallowed a goat. |
| 42 | +Just opened her throat and swallowed a goat! |
| 43 | +She swallowed the goat to catch the dog. |
| 44 | +She swallowed the dog to catch the cat. |
| 45 | +She swallowed the cat to catch the bird. |
| 46 | +She swallowed the bird to catch the spider that wriggled and jiggled and tickled inside her. |
| 47 | +She swallowed the spider to catch the fly. |
| 48 | +I don't know why she swallowed the fly. Perhaps she'll die. |
| 49 | +
|
| 50 | +I know an old lady who swallowed a cow. |
| 51 | +I don't know how she swallowed a cow! |
| 52 | +She swallowed the cow to catch the goat. |
| 53 | +She swallowed the goat to catch the dog. |
| 54 | +She swallowed the dog to catch the cat. |
| 55 | +She swallowed the cat to catch the bird. |
| 56 | +She swallowed the bird to catch the spider that wriggled and jiggled and tickled inside her. |
| 57 | +She swallowed the spider to catch the fly. |
| 58 | +I don't know why she swallowed the fly. Perhaps she'll die. |
| 59 | +
|
| 60 | +I know an old lady who swallowed a horse. |
| 61 | +She's dead, of course! |
| 62 | +``` |
| 63 | + |
| 64 | +[cumulative-song]: https://en.wikipedia.org/wiki/Cumulative_song |
0 commit comments