Polyglot Anagrams Cops' Thread

45

3

This challenge has two threads. This is the cops' thread. The robbers' thread is located here.

Your challenge is to choose an OEIS sequence and write two full programs in two different languages that produces that nth item in the sequence when given an n via STDIN, or an other forms of standard input, where n is any positive number. However your two programs must be anagrams, meaning each can be rearranged from the other's letters.

Programs must output the decimal of the number followed by optional whitespace to STDOUT. Programs may output to STDERR however it should be ignored and if the hidden case does so it must be clearly stated that this is the case.

If you wish you may also output by character code. However if you do so in your hidden solution you must state such in the body of your submission.

You will then present the OEIS number, the source code for and the name of one language it is in.

Robbers will crack your submission if they find an anagram of the original submission that runs in a language other than the one you already presented. To crack an answer they must only find any language and program which produces the sequence and is an anagram of the original, not necessarily the answer the you were thinking about.

Thus you are incentivized to make it as hard as possible to find any language that does the task using their list of symbols.

Scoring

This is so the shortest un-cracked program is the winner.

Languages

Languages will be considered different if the two proposed solutions do not complete the task in both languages. This will include different versions of the same language as long as neither the cop's solution or the robber's solution produce the correct output in the other's language.

i.e. If the there are two solutions 1 and 2 that are in language A and B respectively solution 2 must not produce the correct output in language A and solution 1 must not produce the correct output in language B.

Safety

Once your submission has been uncracked for a week you may post your solution and declare your post safe. If after a week you choose not to post a solution your answer may still be cracked.

Post Rock Garf Hunter

Posted 2016-11-09T14:36:05.490

Reputation: 55 382

4

To browse through random OEIS sequences for ideas, go to https://oeis.org/webcam

– mbomb007 – 2016-11-09T18:15:20.657

How would it work with languages that like to use flags to the interpreter, such as perl? Are they disqualified? Are flags counted as part of the code? Are flags "free" (not included in code or divulged at all)? – Emigna – 2016-11-09T19:19:13.567

Can the hidden program exit with an error (after producing the output)? Should that be indicated in the answer? – Luis Mendo – 2016-11-09T19:34:49.487

@LuisMendo That is fine but should be indicated. – Post Rock Garf Hunter – 2016-11-09T19:35:36.900

@Emigna I would like for flags to be divulged if they are not standard flags for running in the language. – Post Rock Garf Hunter – 2016-11-09T19:37:12.327

Grammar nitpick: "Cop's Thread" and "Robber's Thread" should be "Cops' Thread" and "Robbers' Thread" – NobodyNada - Reinstate Monica – 2016-11-09T19:40:35.300

@DrMcMoylex Seeing as I have already done that myself, It is certainly allowed I will update the question – Post Rock Garf Hunter – 2016-11-09T20:16:33.277

I think you should include that in the text – Luis Mendo – 2016-11-09T20:24:03.357

Some reading for writing CnR challenges. – Martin Ender – 2016-11-09T20:57:06.827

Is it allowed to input/output a character, and use their character code to represent the numbers? – jimmy23013 – 2016-11-09T21:42:01.507

@jimmy23013 No. – Post Rock Garf Hunter – 2016-11-09T21:42:28.140

@WheatWizard I want to enter a java entry but can people just switch the names of the variables and call it a done deal? – tuskiomi – 2016-11-09T21:51:47.913

@tuskiomi No they cannot. The polyglot needs to be in different language. – Post Rock Garf Hunter – 2016-11-09T21:53:55.543

If the crack doesn't print the exact output, but still a understandable format of the sequence, does it count? – Rɪᴋᴇʀ – 2016-11-10T03:34:08.187

@EasterlyIrk As long as both are proper formats they do not have to be the same – Post Rock Garf Hunter – 2016-11-10T03:37:23.360

@WheatWizard :/ even if the output formats were known? – Rɪᴋᴇʀ – 2016-11-10T03:52:42.133

@EasterlyIrk what do you mean? – Post Rock Garf Hunter – 2016-11-10T03:53:19.500

@WheatWizard it was different from the output format of the real crack and the output of the given code. – Rɪᴋᴇʀ – 2016-11-10T03:54:18.197

@EasterlyIrk yes that is still a valid crack – Post Rock Garf Hunter – 2016-11-10T03:54:48.413

@WheatWizard oh well – Rɪᴋᴇʀ – 2016-11-10T03:54:56.227

Can it be output like [<number>]? – Rɪᴋᴇʀ – 2016-11-10T04:17:05.227

Let us continue this discussion in chat.

– Post Rock Garf Hunter – 2016-11-10T04:17:19.557

My Python submission is correct for the first 15 entries, but loses precision after that. The anagrammed solution has exactly the same problem. Can I keep it, mentioning that it's accurate to 15 terms? (I can't imagine that no other submissions lose precision at some point...) – ETHproductions – 2016-11-11T03:03:29.923

@ETHproductions I assume that this is a floating point error, so I think that as long as you are specifying that it is looses precision and both solutions would work as intended given infinite floating precision you are ok. – Post Rock Garf Hunter – 2016-11-11T06:28:10.083

1

Not sure if this would be helpful to anyone else but this highlights any remaining missing characters or any duplicated ones: http://codepen.io/anon/pen/BQjxRK

– Dom Hastings – 2016-11-11T08:12:56.783

1It'd be nice if there was a stack snippet to show uncracked answers, oldest first. – mbomb007 – 2016-11-16T15:57:30.530

Answers

15

Python 2, 118 bytes, A042545 Cracked

i=input();s=1/(801**.5-28);a=[0,1]
for p in range(i):a+=[a[-2]+a[-1]*int(s)];s=1/(s-int(s))
print a[i]#,,,.//000fhlmo|

I didn't feel like implementing a trivial sequence, so I decided to go with my PPCG user ID. I wrote this in the other language first, which should give you a clue about what that language is, though I'd bet 100 dollars that this will be cracked in a golfing language before it's cracked in the intended other language.

Note: Due to floating-point precision errors, this is only accurate up to an input of 14. The intended solution is the same way.

Intended solution, JavaScript (ES7)

for(i=prompt(),s=1/(801**.5-28),a=[1,0];i--;s=1/(s-n))
  n=s|0,a.unshift(a[1]+a[0]*n);
alert(a[0])  //#+2:[]giiiiinnpt

Works in pretty much the same way as the Python solution, though the sequence is stored largest-first rather than smallest-first due to the fact that JS does not support negative indexing.

ETHproductions

Posted 2016-11-09T14:36:05.490

Reputation: 47 880

2I can't get the case of A042545(15) to work. OEIS says that it is 53000053, but your program says that it is 27666361 (at least on my machine). – boboquack – 2016-11-10T22:38:19.300

@boboquack The output for 16 is actually 53000053, but after that there doesn't seem to be any matching terms. I wonder why... – ETHproductions – 2016-11-11T01:33:48.467

Maybe a floating point error that gets progressively worse? – boboquack – 2016-11-11T01:45:09.180

Maybe try codereview.stackexchange.com – boboquack – 2016-11-11T02:20:42.190

Let us continue this discussion in chat.

– ETHproductions – 2016-11-11T02:21:24.857

3Cracked. – Dennis – 2016-11-11T06:11:18.263

1

Dammit, I was right! :( This was as close as I got: https://gist.github.com/dom111/bd9be933cb8ccd0e303601bf73d525b6 Thanks for the workout anyway, I needed |() but just couldn't get them!

– Dom Hastings – 2016-11-11T14:34:23.633

10

Brain-Flak, 24 bytes, A000290, Safe

Yet another square solution. This time there is nothing but parentheses

({(({}[()])()){}[()]}{})

The intended solution was in Brain-Flueue, a version of brain-flak that uses queues instead of stacks. The program was:

({(({})[()]){}}{})[()()]

The languages are considered distinct because neither of the two programs halt when run in the other language.

Post Rock Garf Hunter

Posted 2016-11-09T14:36:05.490

Reputation: 55 382

This would work in Glypho if input/output using character code is allowed... – jimmy23013 – 2016-11-09T21:51:00.893

@jimmy23013 what is Glypho? – Post Rock Garf Hunter – 2016-11-09T21:51:39.767

6http://esolangs.org/wiki/Glypho ((([{}{}{]]}[)))((){))(} – jimmy23013 – 2016-11-09T21:52:19.630

@WheatWizard If it's cracked, can you edit the answer to show that? – mbomb007 – 2016-11-11T16:52:21.597

@mbomb007 It is not cracked – Post Rock Garf Hunter – 2016-11-11T16:59:53.163

@WheatWizard And why isn't jimmy's comment a crack? It works, doesn't it? – mbomb007 – 2016-11-11T17:21:01.807

@mbomb007 It uses character codes rather than integers. It does perform the square but does not fit the specs – Post Rock Garf Hunter – 2016-11-11T17:33:44.507

Outputting a character as a "byte value" is allowed. A brainfuck solution, for example, is allowed to take input as a byte, and output as a byte, even though the output appears as a character. I've done it on challenges before. http://meta.codegolf.stackexchange.com/a/4719/34718

– mbomb007 – 2016-11-11T17:42:42.110

@mbomb007 I have already been very specific about the I/O on this challenge. While I do respect the consensus of the meta I do not believe that this is a typical challenge. – Post Rock Garf Hunter – 2016-11-11T17:52:10.667

@jimmy23013 http://meta.codegolf.stackexchange.com/a/4719/34718

– mbomb007 – 2016-11-11T18:09:51.910

@mbomb007 It's understandable to override the default in this challenge. So I asked in a comment to this question. It's better to edit that into the question though. – jimmy23013 – 2016-11-11T19:18:09.013

Also, the spec in the only listed interpreter is different than what the esolangs page says. http://esoteric.voxelperfect.net/files/glypho/doc/glypho.txt

– mbomb007 – 2016-11-11T20:01:01.060

7

Python 2, 38 bytes, A000290 Cracked by Emigna

def e(X):return X*X
print e(input())##

This will probably be very easy to crack. I'm mostly posting this as a starting point.

Orignial solution in CJam:

ri:XX*e#def ()return X
e#pnt (input())

Loovjo

Posted 2016-11-09T14:36:05.490

Reputation: 7 357

2Cracked – Emigna – 2016-11-09T15:56:32.100

7

CJam, 7 bytes, A005843 Cracked!

ri2*e#^

This is a basic 2*n sequence.

Explanation:

r          e# read input
 i         e# convert to integer
  2*       e# multiply it by 2
    e#^    e# this is a comment that is ignored by the interpreter

Try it online!


Original Solution, Carrot

#^i*2er

Carrot is an esolang created by me. I have stopped developing it a long time ago. The reason I chose this is because I hoped that it would be hard for other languages to comment out the unnecessary parts of the code.

Explanation:

#^            This pushes the input to the stack (anything before the ^ is the stack)
  i           Convert stack to integer
   *2         Multiply it by 2
     er       These are ignored because they are not Carrot commands
              Implicit output

Try it online!

user41805

Posted 2016-11-09T14:36:05.490

Reputation: 16 320

1ri#e^*2 would work in Jelly if * were multiplication instead of exponentiation. So close... – ETHproductions – 2016-11-09T17:31:49.777

3Cracked :). – Adnan – 2016-11-09T19:38:20.017

I had everything but the r in pyth. Exciting to see the original code for this one. – Emigna – 2016-11-09T20:34:55.780

1@Emigna I added the original code – user41805 – 2016-11-10T07:45:19.910

6

2sable, 15 bytes, A000290, Cracked!

Hopping on the same n2 train :p.

*?"!#$&<=@\^{|}

Try it online!

Adnan

Posted 2016-11-09T14:36:05.490

Reputation: 41 965

2Almost looks like Malbodge with the symbols in order like that :P – ETHproductions – 2016-11-09T17:05:27.897

3Cracked :D – Conor O'Brien – 2016-11-09T23:55:47.043

1@ConorO'Brien Hahaha, I was pretty certain this wasn't possible in Jelly, Pyth, 05AB1E and MATL. Nice job! :) – Adnan – 2016-11-10T10:31:27.487

5

Brain-Flak, 44 bytes, A000290 Cracked

<({({})({}[()])}{}))()()()turpentine/"*"*4splint>

Try it online!


Original solution, Python 2

print(input()**(len(set("{}{}{}[]()<>"))/4))

Post Rock Garf Hunter

Posted 2016-11-09T14:36:05.490

Reputation: 55 382

2Cracked :) – Adnan – 2016-11-09T16:00:54.373

Now I'm really curious. What was your original intended solution? I can tell it's python because I see len set input and print (and because I know you like python) but I can't figure out how that squares a number – James – 2016-11-09T16:02:59.930

@DrMcMoylex added – Post Rock Garf Hunter – 2016-11-09T16:05:13.093

5

Excel, 12 bytes, A000012 Cracked

=IF(1=1,1,1)

Maybe not the toughest, but a fun one to crack.

tuskiomi

Posted 2016-11-09T14:36:05.490

Reputation: 3 113

Cracked – Emigna – 2016-11-09T20:31:14.033

5

Python 2, 25 bytes, A000583, cracked

Y=input("");print`Y**4`,X

This program exits with an error after printing the output.


My hidden code (substantially different from the cracked solution!):

Actually, 25 bytes

4,n`*`Y")ii(*nppruttY;="X

Try it online!

Explanation:

4,n`*`Y")ii(*nppruttY;="X
4,n                        input, repeat 4 times
   `*`Y                    do * until the stack stops changing (fixed-point combinator)
       ")ii(*nppruttY;="X  push this string and immediately pop and discard it

Mego

Posted 2016-11-09T14:36:05.490

Reputation: 32 998

Cracked – Adnan – 2016-11-10T11:40:46.407

5

Python 2, 124 bytes, A144945, [Safe]

Cracking this would have earned you a 500 rep bounty! Too late!

Number of ways to place 2 queens on an n X n chessboard so that they attack each other.

I hope it's not too easy. I arranged my code so the whitespace is clearly visible. Those are spaces and newlines only.

Note: intended solution outputs via character code

n=input();print((3+2)*n*n+~0*6*n+1)*n/3;            +6;



























+7+7+7+7+7+7+7+7+7;+++++++++++++++9+9*9*9

Try it online

Intended Solution, Headsecks:

r2=ni***p**
(


p((0 ;3+++3;+;/


)





i+++nn
 +)7
n

n+++ 


17+~
 +)7;97++++7


69+9n+ ++7+n 69
 +7+ ++7


**7+++tut

This is equivalent to the following BF program:

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

mbomb007

Posted 2016-11-09T14:36:05.490

Reputation: 21 944

5

Python, 118 bytes, A042545, Safe

i=int(input());s=pow(801.0,0.5);a=[0|0,1]
for Moshprtflmah in range(i):s=1./(s%1);a+=[a[-2]+a[-1]*int(s)];
print(a[i])

This time it works in both 2 and 3. And there's no comments! What will you do?

Note: As with the old solution, this loses precision after the first 15 terms due to floating-point arithmetic errors.

Intended solution, JavaScript (ES6)

giiiiinnnnprt:
i=prompt([n=+2]);s=Math.pow(801,.5);for(a=[1,0];i--;a.unshift(a[1]+a[0]*(s|0)))s=1/(s%1)
alert(a[0])   

Though I kept several old versions, I somehow managed to lose this copy, but fortunately piecing it together from the others wasn't too hard. I see now that I had an extraneous prt in both programs that could have been golfed out. Oh well.

ETHproductions

Posted 2016-11-09T14:36:05.490

Reputation: 47 880

I thought I would remind you that you can mark this as safe if you wish. – Post Rock Garf Hunter – 2017-01-01T23:39:26.480

@WheatWizard Thanks, I've added my intended solution. – ETHproductions – 2017-01-18T18:28:10.870

4

Fuzzy Octo Guacamole, 26 bytes, A070627 [Safe]

49++*5^pm#]%:"?:.=:#,|"1:@

Test cases:

1 -> 1
3 -> 23
5 -> 1

Solution:

^::::|*?1=#@]","%.#49++5pm

Works in Magistack.

Rɪᴋᴇʀ

Posted 2016-11-09T14:36:05.490

Reputation: 7 410

Hello! Just reminding you that this answer can be marked as safe. No need to rush but no one has cracked it in a week. Good job, I am eager to see a solution – Post Rock Garf Hunter – 2016-11-17T19:51:44.717

Cool, I'll do it and the other once when I get home. – Rɪᴋᴇʀ – 2016-11-17T21:30:40.787

3

Python 2, 37 bytes, A000290 Cracked

print(input()**(1+1))
"'10°3¢','m'"

Oliver Ni

Posted 2016-11-09T14:36:05.490

Reputation: 9 650

3Cracked – Emigna – 2016-11-09T16:31:03.640

3

MATL, 7 bytes, A000217, cracked

:sp{1}x

The sequence is n(n+1)/2 (triangular numbers), starting at input n=1 as specified by the challenge: 1, 3, 6, 10, ... (Output for input 0 is not guaranteed to be the same in the two programs).

The program in the other language exits with an error (after producing the correct output in STDOUT).

Try it online!

:            % Push [1 2 ... n], where n is implicit input
 s           % Sum of that array. Gives the desired result
   p         % Product of that. Gives the same number
    {1}      % Push a cell array containing number 1
       x     % Delete it

Luis Mendo

Posted 2016-11-09T14:36:05.490

Reputation: 87 464

1Cracked! – Steven H. – 2016-11-10T03:38:49.580

@StevenH.Well done! My original solution was x:ps{}1 – Luis Mendo – 2016-11-10T07:54:32.827

3

Fuzzy Octo Guacamole, 11 bytes, A001844 [Safe!]

hha02^d+**+

A crack that sort-of works is dh*h++^2*0a, in Pyth. It's not the right output format though.

My code is still out there! (and it's not in Pyth)

Test Cases:

0 -> 1
1 -> 5

Solution:

^++d0ah*2*h

In Jolf.

Rɪᴋᴇʀ

Posted 2016-11-09T14:36:05.490

Reputation: 7 410

1I swear, this looks like it was made for Jolf, but I just can't figure out that d... – ETHproductions – 2016-11-10T02:14:52.620

Cracked (I hope...) – ETHproductions – 2016-11-10T02:33:36.950

@ETHproductions ah, nice. Not sure if it counts though? See edit. – Rɪᴋᴇʀ – 2016-11-10T02:56:36.563

My code prints a newline, but no space. Same with the valid code. – Rɪᴋᴇʀ – 2016-11-10T02:57:34.470

@EasterlyIrk Despite what I said I do not consider the answer provided a crack. I everything I said still holds true however I do not consider leading whitespace valid output and I will amend the question to reflect that. – Post Rock Garf Hunter – 2016-11-10T03:58:32.860

@ETHproductions ^ – Rɪᴋᴇʀ – 2016-11-10T04:18:01.683

@WheatWizard OK, I've deleted my post. – ETHproductions – 2016-11-10T12:37:06.520

This answer can also be marked as safe at your own disgression. – Post Rock Garf Hunter – 2016-11-17T19:52:34.480

3

Pyth, 75 bytes, A004526 Cracked, milk

More of a playful test than anything, but:

/Q/////////////////****22222 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2;;;;;

Try it online!

Milk's solution (Convex):

2/Q2 2/2/2/2/2/2/2/2/2/2/2/2/2/2/2/2/2/2*2*2*; 2*;                 2; 2; 2;

Try it online

Intended solution (///):

/*///;2/;// ///22/Q//2;///;//;***2222222222222222222222                    

Try it online

Takes input in the form of 2's before the last semicolon and outputs the correct number of Q's.

The sequence is 0-indexed (i.e. 0 is 0, 1 is 0, 2 is 1, ...)

Found slight syntactical mistakes in the ///, so edited all solutions.

boboquack

Posted 2016-11-09T14:36:05.490

Reputation: 2 017

Cracked – milk – 2016-11-10T07:32:46.287

3

Python 3, 27 bytes, A000012, Cracked

No input this time!

if 1:
    if 1:
        print( '1' )

The indents are tabs, but not to save bytes - they are required for whitespace.

I don't think it needs a TIO link or explanation!

(Probably won't take long to crack in some way)

Intended answer (Whitespace):

-Start-


    if1:if1:print('1')
-End-

(Start and end not part of the program)

Sorry, I forgot to add that it prints to STDERR:

Try it online!

boboquack

Posted 2016-11-09T14:36:05.490

Reputation: 2 017

1Cracked. – milk – 2016-11-10T22:11:52.753

I feel like this is supposed to be Whitespace, but that would print an error to STDERR as it's lacking the required linefeeds to end in [LF][LF][LF]. – Martin Ender – 2016-11-10T22:12:42.367

1@milk Not you again! :D – boboquack – 2016-11-10T22:16:24.340

1@boboquack It does work, but it does print to STDERR (which you can see by activating the Debug mode on TIO), and the challenge says that answers need to specify whether the hidden language writes to STDERR. – Martin Ender – 2016-11-10T22:23:06.660

Cracked again. – Oliver Ni – 2016-11-11T05:01:02.140

@Oliver can't find your crack... – boboquack – 2016-11-11T05:38:30.517

@boboquack I deleted it as it has already been cracked. – Oliver Ni – 2016-11-11T05:38:57.937

2

MATL, 13 bytes, A002275 Cracked!

i:"@ax'1']
v!

Try it online!

Explanation:

i           % Grab input
 :          % Push (range(1,input))
  "         % For each element in this range:
   @        %   Push it
    a       %   Is is truthy?
     x      %   Delete it
      '1'   %   Push '1'
         ]  %   End loop
v           % Join all of these '1's together
 !          % Transpose and display

James

Posted 2016-11-09T14:36:05.490

Reputation: 54 537

1I feel like this is in Vim but for the life of me I can't crack it – Post Rock Garf Hunter – 2016-11-09T19:47:34.887

Cracked :) – Post Rock Garf Hunter – 2016-11-10T01:13:49.410

2

WinDbg, 39 bytes, A000007 Cracked by jimmy23013

~e.block{j(0>=@$t0)?@$t0+(1<7);??0}t":"

The difficult sequence of 0**n.

Input is done by passing a value in the pseudo-register $t0.

My original solution was C#:

@t=>(object)(0<@t?0:1)??"$$700~lk.{}+";

milk

Posted 2016-11-09T14:36:05.490

Reputation: 3 043

1Cracked. – jimmy23013 – 2016-11-09T21:02:47.837

2

JavaScript ES6, 38 bytes, A000290, Cracked

J=>eval(Array(J).fill(J).join`+`)|2-2;

This square train is pretty nifty, but isn't going anywhere fast. (Get it? square train? as in, wheels? no? okay, fine. critics.)


Intended answer: Reticular (Try it online!),

in2Jo;=>eval(Array(J).fill(J).j`+`)|-2
in      take input, convert to number
  2J    raise to the second power
    o;  output and terminate; ignores following chars

Conor O'Brien

Posted 2016-11-09T14:36:05.490

Reputation: 36 228

2Your code is trying to convince me that the other language is J :P – ETHproductions – 2016-11-09T23:50:18.667

Cracked. – Post Rock Garf Hunter – 2016-11-10T00:37:00.320

2

2sable, 13 bytes, A002378, Cracked!

Hoping I didn't miss something. Computes a(n) = n × (n + 1):

>*?"!&)<=@\\}

My version:

?"\>@&*})<\=!

Or the unfolded version:

  ? " \
 > @ & *
} ) < \ =
 ! . . .
  . . .

Note that the > in the top-left corner is unused (except for the 2sable program). I did this to confuse the robbers (but that obviously didn't work haha).

Try it online!

Adnan

Posted 2016-11-09T14:36:05.490

Reputation: 41 965

Cracked. :) – Martin Ender – 2016-11-10T12:46:09.300

@MartinEnder Nice job! I'll update my answer with the original submission :). – Adnan – 2016-11-10T13:08:28.113

2

Python 2, 35 bytes, A048735, Safe

print(lambda u:u&u<<1)(input())>>1

The original solution was in my own programming language Wise.

:<<>&>print(lambda uuu1)(input())1

Most of the characters are irrelevant no-ops. The important characters are the first six. : creates two copies of the first item on the stack. <<> bit shifts twice to the left and once to the right which is equivalent to bit shifting once to the left. & takes the bitwise and of the top and second item (the original and the bit shifted copy). Lastly > bit shifts once to the right.

Post Rock Garf Hunter

Posted 2016-11-09T14:36:05.490

Reputation: 55 382

2

05AB1E, 5 bytes, A000012, Safe

$;$1?

Sequence of 1's. Try it online

Intended Solution: Arcyou

1;$$?

Try it online. I couldn't find documentation for this language, so don't have an explanation of how it works exactly.

milk

Posted 2016-11-09T14:36:05.490

Reputation: 3 043

Stupid semicolon... I could almost use Retina, but I can't have both the 1 and ;. – mbomb007 – 2016-11-11T16:47:35.723

1This has not been cracked – Post Rock Garf Hunter – 2016-11-12T17:44:37.670

It looks like this answer can now be marked as safe. Since I spent quite a deal of time trying to crack this one I am quite eager to see the intended answer. – Post Rock Garf Hunter – 2016-11-17T19:59:51.920

Shouldn't this answer be marked as "accepted" now? – mbomb007 – 2017-02-09T16:49:00.760

2

Befunge 93, 14 bytes, A121377, Cracked by milk!

&52* %68*+ .@Q

Fun fact: The intended solution to this is the first time I've ever used that language.

My solution in Pyth. &@ print an error, but that goes to STDERR which according to the OP is ignored.

+%Q*5 2*6 8.&@

Daniel

Posted 2016-11-09T14:36:05.490

Reputation: 6 425

Cracked – milk – 2016-11-11T06:55:00.653

2

2sable, 15 bytes, A087156

D1QiA0*<}.;2->>

Try it online

The sequence of non-negative numbers, except for 1.

milk

Posted 2016-11-09T14:36:05.490

Reputation: 3 043

1

Python 2, 70 Bytes, A000217 Cracked!

I have a feeling this won't be cracked in the language I used for the other version, we will see :)

o=input()
v=0
i=1
while o:
 v+=i
 i+=1
print v


#|  d00->1@@@++-^,,[

I realized afterwards I had incorrectly obfuscated the code (it doesn't change the posted answer's validity). Here's the code I started with in Haystack:

v
0
v
0
i
1
-
>      d0[v
^-1@+@d+1@?,,o|

Kade

Posted 2016-11-09T14:36:05.490

Reputation: 7 463

1Cracked. – jimmy23013 – 2016-11-09T20:47:01.430

1

05AB1E, 9 bytes, A000042 Cracked!

1×,1*-^$)

This is the Unary representation of natural numbers (OEIS). So if the input was 3, for example, then output would be 111.

Explanation:

                    # implicit input
1                   # pushes 1 to the stack   
 ×                  # pushes "1" × (the input)
  ,                 # outputs the stack
   1*-^$)           # irrelevant

Try it online!


Original Solution, Carrot

1^*$-1×^)

Explanation

1^             Push "1" to the stack
  *            Multiply the string by
   $-1         ...the input (as an integer) minus 1 times
      ×,)      Ignored by the interpreter

The * multiplies the string by (n+1) times, so that a^*3 results in aaaa and not aaa. So that is why I subtracted 1 from the input.

Only now I realise that the ) has been irrelevant in both the languages :D

Try it online!

user41805

Posted 2016-11-09T14:36:05.490

Reputation: 16 320

Cracked. – Oliver Ni – 2016-11-10T17:39:32.820

What was the original hidden language? – Post Rock Garf Hunter – 2016-11-10T17:53:38.347

@WheatWizard Whoops, thanks for finding that. I added the language now – user41805 – 2016-11-10T17:54:59.913

1

05AB1E, 8 bytes, A000042, Cracked

F1}J,(1&

Test cases:

1 -> 1
2 -> 11
3 -> 111

Oliver Ni

Posted 2016-11-09T14:36:05.490

Reputation: 9 650

Cracked – user41805 – 2016-11-10T20:21:46.657

1

J, 2 bytes, A000290, Cracked

*~

Well, might as well start going for those two-byters. Yields n × n, or n2.

intended solution, Jolf, 2 bytes

*~

Well. Yeah. This is my own language and I think it works because ~ looks for an extended character, but doesn't find one, so it just ignores it. ¯\_(ツ)_/¯ Oops.

Conor O'Brien

Posted 2016-11-09T14:36:05.490

Reputation: 36 228

2Cracked! – Steven H. – 2016-11-11T01:27:23.780

@StevenH. nice job! I edited with intended solution. – Conor O'Brien – 2016-11-11T01:30:27.730

@ConorO'Brien your intended solution was not a valid solution. In order for languages to be considered distinct neither the original or the solution can be a polyglot in both languages – Post Rock Garf Hunter – 2016-11-11T01:31:50.143

@WheatWizard Oh. That's awkward. – Conor O'Brien – 2016-11-11T01:33:41.030

1

ABCR, 24 bytes, A023443 Cracked!

70: Quit xi. Classy queue!

There's a bunch of no-ops. Calculates n - 1.

Steven H.

Posted 2016-11-09T14:36:05.490

Reputation: 2 841

1

Ouroboros, 6 bytes, A000012 Cracked

)49.o(

Always outputs 1.

DLosc

Posted 2016-11-09T14:36:05.490

Reputation: 21 213

Cracked. – ETHproductions – 2016-11-11T17:41:32.160

@DLosc sorry for posting in the wrong place but you haven't been on chat in ages ;_; – ASCII-only – 2016-11-12T00:14:35.213

1

05AB1E, 5 bytes, A005843

ApDF>

Calculates n*2.

Oliver Ni

Posted 2016-11-09T14:36:05.490

Reputation: 9 650

This is NOT cracked because I just found out that my crack was invalid. I have deleted it now because it is invalid since the original program was a polyglot in 05AB1E/2sable. – user41805 – 2016-11-13T06:05:43.180

0

05AB1E, 5 bytes, A000012 Cracked!

¸WW/`

The funny thing is that the cracked version is the intended answer.

Try it online!

Oliver Ni

Posted 2016-11-09T14:36:05.490

Reputation: 9 650

1It outputs nothing when the input is 0 – user41805 – 2016-11-11T16:55:30.637

And it outputs 21 when input is 42 Here

– user41805 – 2016-11-11T16:56:39.560

@KritixiLithos There. – Oliver Ni – 2016-11-11T17:10:41.753

Now it outputs 1.0 instead of 1 – user41805 – 2016-11-11T17:19:21.017

@KritixiLithos It's the same thing. – Oliver Ni – 2016-11-11T17:19:41.033

1Cracked! :) – user41805 – 2016-11-11T17:32:19.160