3
2
Inspired by this challenge
Given a number m
, output a program that prints out the string Do not repeat yourself
.
Now for the challenging part: Each program the original code prints out has to have the byte at place m*n
be the same as m*n + 1
and the same as m*n + 2
.... all the way down to m*n + m - 1
.
(In case you can't tell, that means it has to be blocks of identical bytes m
long)
Example (that only demonstrates the repetition rule, not the output):
2
aassdd
3
mmmyyy nnnaaammmeee iiisssfffrrreeeddd
27
111111111111111111111111111
Scoring:
- Your program's score is the
x / (min(y, 10)^3)
, wherey
is the number of correct programs it outputs, andx
is the sum of the lengths of all of the correct programs it outputs andx > 1
. Lowest score wins.
Other notes:
Your code doesn't have to fulfill any such restrictions on letters repeating.
Your programs (that you output) cannot take input of any sort.
The input will always be a positive integer greater than 1.
Your code needs to work for at least one integer greater than 1.
1Would interface{static void main(String[]a){System.out.print("Do not repeat yourself");}} be considered acceptable. I am unsure of exactly what you are asking? – Rohan Jhunjhunwala – 2016-07-09T15:56:38.613
@RohanJhunjhunwala Your program needs to have blocks of characters of
<input>
length, e.g. for input2
something likeaabbccdd
. – Rɪᴋᴇʀ – 2016-07-09T15:58:13.153Oh sorry I misread the question @Easterly IRk – Rohan Jhunjhunwala – 2016-07-09T15:58:30.793
3Doesn't your challenge description disqualify most normal languages? – Rohan Jhunjhunwala – 2016-07-09T15:59:02.813
Like a language with boilerplate? – Rohan Jhunjhunwala – 2016-07-09T15:59:18.547
@RohanJhunjhunwala most languages don't use a boilerplate, and yes, it makes most languages extremely hard. The point is the creativity though. – Rɪᴋᴇʀ – 2016-07-09T16:00:17.270
1Why do we have to take input if we're printing a static string? – James – 2016-07-09T16:01:06.987
1@Esterly Irk is this challenge possible to be done in java? I feel like its provably impossible – Rohan Jhunjhunwala – 2016-07-09T16:01:32.840
@RohanJhunjhunwala I have no clue. But it's possible it at least 1 langauge. – Rɪᴋᴇʀ – 2016-07-09T16:02:02.763
@DrGreenEggsandIronMan you are supposed to print more than 1 different output. The output should be different for 2 and 4, for example. – Rɪᴋᴇʀ – 2016-07-09T16:02:57.237
What if someone creates one program that works for any m? – Rohan Jhunjhunwala – 2016-07-09T16:08:10.073
@RohanJhunjhunwala doubtful that would happen, and it would be
Inf/10^3
score. That would probably end a win/tiebreaker of earliest answer. – Rɪᴋᴇʀ – 2016-07-09T16:17:24.993So a score of 0? – Rohan Jhunjhunwala – 2016-07-09T16:18:03.500
@RohanJhunjhunwala If you have any more comments, please say them in chat. This is really polluting the comments. – Rɪᴋᴇʀ – 2016-07-09T16:19:00.080
Let us continue this discussion in chat.
– Rohan Jhunjhunwala – 2016-07-09T16:19:15.740The description of this challenge is unclear to the point of unreadability.
n
is used before being defined (it's never defined?). What is the output supposed to be for a given input? Your examples do not clarify anything. – sintax – 2016-07-13T17:01:08.413