-7
\$\begingroup\$

It is only Tuesday, ugh. I deserve a treat. Golf me a Castle. The Least amount of bytes wins!

Taken no input and output this image exactly:

 /\           /\
/  \         /  \
----         ----
|  |^^^^^^^^^|  |
-----------------
|       _       |
|   |  | |  |   |
|      | |      |

Edit

Build me a brick wall! 36 votes versus my -9. Okay.

\$\endgroup\$
  • \$\begingroup\$ shortest code or lowest byte count.? \$\endgroup\$ – FivePixels Nov 8 '16 at 20:02
  • \$\begingroup\$ Least amount of bytes \$\endgroup\$ – jacksonecac Nov 8 '16 at 20:03
  • 3
    \$\begingroup\$ @dylan What's the difference? \$\endgroup\$ – DJMcMayhem Nov 8 '16 at 20:55
  • \$\begingroup\$ @DrMcMoylex codegolf.stackexchange.com/a/17020/61857 \$\endgroup\$ – FivePixels Nov 9 '16 at 17:49
  • 1
    \$\begingroup\$ my post was ironic to the date + was fairly simple. yours seems much more complicated and more diverse which is why i didn't take a stab at it. \$\endgroup\$ – FivePixels Nov 10 '16 at 14:23
4
\$\begingroup\$

Bubblegum, 52 bytes

00000000: 35c8 3111 c030 1443 b1fd a310 815c 08f5  5.1..0.C.....\..
00000010: 5a22 06df 64b0 263f db0f 7562 367d b831  Z"..d.&?..ub6}.1
00000020: eb50 3726 e4ad 9059 5513 c007 c804 2142  .P7&...YU.....!B
00000030: f441 74fc                                .At.

Obligatory Bubblegum answer.

\$\endgroup\$
2
\$\begingroup\$

Ruby, 130 bytes

f=->a,b=' '{a+b*9+a};g=->s{?|+s.center(15)+?|};puts f[' /\\ '],f['/  \\'],f[c=?-*4],f[d='|  |',?^],f[c,?-],g[?_],g[d+' '+d],g['| |']

This can probably be golfed down more.

\$\endgroup\$
2
\$\begingroup\$

Swift 3, 200 bytes

var z=" /\\ 9/\\\n/  \\ 7/  \\\n-2 7-2\n|  |^7|  |\n-95\n| 5_ 5|\n| 1|  | |  | 1|\n| 4| | 4|",o="",x=""
for c in z.characters{let k="\(c)"
if let b=Int(k){for i in 0...b{o+=x}}else{o+=k
x=k}}
print(o)

Basically loop trough the Characters of z string, if a digit (b) is found then repeat the last character b+1 times

Try online here

\$\endgroup\$
0
\$\begingroup\$

JavaScript (ES6), 120 bytes

_=>` /\\44/\\
/8\\36/8\\
173617
|8|38|8|
69
|28_28|
|12|8| |8|12|
|24| |24|`.replace(/\d\d?/g,n=>' -^'[n&3].repeat(n/4))

Demo

let f =

_=>` /\\44/\\
/8\\36/8\\
173617
|8|38|8|
69
|28_28|
|12|8| |8|12|
|24| |24|`.replace(/\d\d?/g,n=>' -^'[n&3].repeat(n/4))

console.log(f())

\$\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.