Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
22 added 196 characters in body
source | link

Remark: I may golf it more by 3 bytes but by doing so, mine and WheatWizard's answer would have the exact same logic. The result is probably the shortest GraySnail solution and I'm trying to prove it.

Remark: I may golf it more by 3 bytes but by doing so, mine and WheatWizard's answer would have the exact same logic. The result is probably the shortest GraySnail solution and I'm trying to prove it.

21 added 3 characters in body
source | link

Gray Snail, 1206 bytes for numeric I/O, 156149 bytes for unary I/O

Standalone version, 156149 156 157 167 170 230 bytes, only support unary I/O

INPUT A
INPUT B
INPUT C
POP H N H .
GOTO U
$
POP ZN A [A].[A][C]
POP Z NH ..[N]
GOTO D [A] 
GOTO $ [B] [N][H]
GOTO U
$
POP Z A .[A][C][A]
POP Z HN ..[H][N]
POPGOTO ND Z[A] 
GOTO $ .[B] [N]
GOTO U
D
OUTPUT .[H]

Gray Snail, 1206 bytes for numeric I/O, 156 bytes for unary I/O

Standalone version, 156 157 167 170 230 bytes, only support unary I/O

INPUT A
INPUT B
INPUT C
POP H N .
U
POP Z A [A]
POP Z N ..[N]
GOTO D [A] 
GOTO $ [B] [N]
GOTO U
$
POP Z A .[A][C]
POP Z H ..[H]
POP N Z 
GOTO U
D
OUTPUT [H]

Gray Snail, 1206 bytes for numeric I/O, 149 bytes for unary I/O

Standalone version, 149 156 157 167 170 230 bytes, only support unary I/O

INPUT A
INPUT B
INPUT C
POP N H .
GOTO U
$
POP N A .[A][C]
POP Z H ..[H]
U
POP Z A [A]
POP Z N ..[N]
GOTO D [A] 
GOTO $ .[B] [N]
GOTO U
D
OUTPUT .[H]
20 deleted 383 characters in body
source | link

I have an 155-byte solution, but it just implements aforementioned abuses on WheatWizard's answer so I won't acknowledge it as mine.

INPUT a
INPUT u
INPUT d
POP f c 
POP f U 
GOTO 1
3
POP f a [a][d]
POP U c ..[c]
1
GOTO 2 [a] 
GOTO 3 [U] [u]
POP f U ..[U]
POP f a [a]
GOTO 1
2
OUTPUT [c].

I have an 155-byte solution, but it just implements aforementioned abuses on WheatWizard's answer so I won't acknowledge it as mine.

INPUT a
INPUT u
INPUT d
POP f c 
POP f U 
GOTO 1
3
POP f a [a][d]
POP U c ..[c]
1
GOTO 2 [a] 
GOTO 3 [U] [u]
POP f U ..[U]
POP f a [a]
GOTO 1
2
OUTPUT [c].
19 added 24 characters in body
source | link
18 deleted 5 characters in body
source | link
17 added 14 characters in body
source | link
16 added 5 characters in body
source | link
15 added 13 characters in body
source | link
14 added 54 characters in body
source | link
13 added 54 characters in body
source | link
12 added 403 characters in body
source | link
11 added 403 characters in body
source | link
10 added 403 characters in body
source | link
9 deleted 584 characters in body
source | link
8 added 1 character in body
source | link
7 added 39 characters in body
source | link
6 added 953 characters in body
source | link
5 added 853 characters in body
source | link
4 added 288 characters in body
source | link
3 deleted 1 character in body
source | link
2 edited body
source | link
1
source | link