63
\$\begingroup\$

Introduction

Bad news guys - you got detention. Your English teacher doesn't understand this site and wants you to "stop doing math on your digital dohickeys, this is English class!"

She sentenced you to write her favorite saying on the blackboard 25 times, which will give a total of 100 lines on the blackboard.

The eighteen-hundreds were a time for rum.
The nineteen-hundreds were a time for fun.
The two-thousands are a time to run
a civilized classroom.

Lucky for you, you are an avid reader (not to mention an expert code-golfer)! You have a read about a trick that might possibly get you off easy.

foxtrot

(Foxtrot by Bill Amend)

Unfortunately for Jason, it didn't work out. But you have a better idea! Since your English teacher thinks you're doing math, if you leave all the numbers out of your program it just might work! You also want to keep your program as short as possible because you are a lazy student and don't want to write a lot on the board.

Write a program that complies with the following rules:

  • Your program must print the 4 above lines 25 times. The lines must be outputted in that order, repeating. Total exactly 100 lines of output (a trailing newline at the very end or a leading newline at the very beginning is okay).
  • You cannot use the characters 0123456789. Your teacher gets confused by math and will call you out!
  • You can use any imports and external libraries without counting the imports. Your English teacher doesn't know about programming. Jason could have saved a lot of work by not writing #include <stdio.h> and you don't want to make his same mistakes!
  • Score your program by byte count. Lowest score wins!
\$\endgroup\$
  • 2
    \$\begingroup\$ If the text would've read "1900s", writing the output would've been slightly more tricky. \$\endgroup\$ – Ingo Bürk Oct 23 '14 at 14:50
  • 29
    \$\begingroup\$ to the comix: he's not printing \n's, and the loop from 1 is pretty awkward (like against C nature)... \$\endgroup\$ – V-X Oct 23 '14 at 15:41
  • 11
    \$\begingroup\$ @V-X Bill Amend is a long-time Pascal die-hard, and whenever he writes C that becomes pretty apparent. \$\endgroup\$ – fluffy Oct 23 '14 at 18:09
  • 5
    \$\begingroup\$ This sounds very much like one of my old English teachers. \$\endgroup\$ – Kaz Wolfe Oct 25 '14 at 16:58
  • 2
    \$\begingroup\$ Banning + would have made sense here, but maybe that would have been too difficult. \$\endgroup\$ – Pharap Oct 28 '14 at 9:38

62 Answers 62

1
\$\begingroup\$

EXCEL , 160 164 bytes

asked Teacher if I could use Excel, Teacher said Yes.

asked Teacher if I could click around, Teacher said Yes.

So click Wrap Text, merge A-TwentyFive to A-OneHundredTwentyFive and Paste this in Cell A-TwentyFive

=REPT("The eighteen-hundreds were a time for rum.
The nineteen-hundreds were a time for fun.
The two-thousands are a time to run
a civilized classroom.
",ROW())
\$\endgroup\$
  • \$\begingroup\$ I count this as 164, did I miss something? \$\endgroup\$ – Origin Apr 16 at 8:18
  • \$\begingroup\$ I'm using TIO to count the bytes of my code. are you referring to the New Line? maybe its not counting it. will add it. Thank you :) \$\endgroup\$ – remoel Apr 16 at 8:41
1
\$\begingroup\$

Brainfuck, 659 bytes

++++++++++++[->>++>+++++++>++++++++>+++>++++++++>+++++++++>+++++++++>+++++++++>++++>+[<]<]>>+>>+>---->++++>+>>--->-->--[<]>[->.>>>++++.---.<.>.>>>.--.+.<<+++++++.<..>>++.>>-.<.<<+.>.<<-.>---.<+.-.>+.<<.>>++++.<+.>-----.<.<.<.>.>>++.>>+.<-.<<.<.>+.>>++.<--.<<.>>.+++.>--.>>+.>.<<<<<<<<.>>>++.---.<.>>>+.>.<.<<.>-.<..>>.>>-.<-.<<+.>.<<-.>---.<+.-.>+.<<.>>++++.<+.>-----.<.<.<.>.>>++.>>+.<-.<<.<.>+.>>++.<--.<<.>.>+++.>-.>>+.>.<<<<<<<<.>>>++.---.<.>>-.+++.>+.>>-.<<<---.>>-.<.<+.--.<<<.>>>>-.<<-.>.<<.<.>>>-.<+.<.<.>.>>++.>>+.<-.<<.<.>>.>++.<<<.>>--.+++.>-.>>>.<<<<<<<.>.<++.>>>>>.<<+.>>.<--.>.<<++++.<.-.<.<.>>>>.<<---.>-------..-.---..--.>>>+.>.<<<<<+++<<--<<]

Try it online!

I found this using my own mediocre Brainfuck cruncher.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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