Today is May 4th, Star Wars day, so here's a Star Wars ASCII-art task. Output this image of an X-Wing starfighter:

\             /
o\           /o
V \(+)___(+)/ V
|  --/ | \--  |
 /    |||    \
/o     |     o\
 V           V
 |           |

Your output may have any extra whitespace that doesn't affect the representation of the image. You may output a list of lines instead of a string with newlines.

This is , so shortest answer wins. May the 4th be with you!

(If it's May 5th in your timezone, try Sith TIE-Fighter)


5 Answers 5


Charcoal, 36 bytes


Try it online! Link is to verbose version of code. Explanation:


Draw the bottom left leg.


Draw the top left leg.


Draw the left body using a compressed string.


Draw the middle of the body.


Reflect to complete the starfighter.


K (ngn/k), 96 bytes

Hardcode the left half, then reverse and replace \/() -> /\)( to get the other half.

`0:"/()\\"{y,1_|y^'x@3-x?y}/:8$";"\"\\;o\\;V \\(+)__;|  --/ |;  /(+)\\|; /    ||;/o     |; V; |"

Attempt This Online!


JavaScript (ES6), 125 bytes

V 0(+)___(+)/ V
|2--/ | 0--2|

Try it online!


Vyxal Drj, 387 bitsv2, 48.375 bytes

` |/\-_)+(Vo`»¬W,Ze:iw≠ꜝ≬⊍eȦR`¡ßdĿ$»τ»÷Ṡ%]»fẇƛ8røM

Try it Online!



-2 bytes thanks to Kevin Cruijssen

  • \$\begingroup\$ The hard-coded string can be »¬W,Ze:iw≠ꜝ≬⊍eȦR`¡ßdĿ$»` |/\-_)+(Vo`τ, although I'm not sure how to combine it with the r flag.. :/ \$\endgroup\$ May 6 at 7:23
  • \$\begingroup\$ r flag just switches the two \$\endgroup\$
    – pacman256
    May 6 at 13:54

05AB1E, 48 bytes


Outputs as a list of lines.

Try it online. (The » in the footer joins the list by newlines. Feel free to remove it to see the actual result.)


Step 1: Draw the left side without trailing spaces:
by using this 05AB1E ASCII-art compression technique

                # Push compressed integer 78542092356563376216422644276947767672388754200679396880402
" \n|/\-_)+(Vo" # Push this string
  Åв            # Convert the integer to custom base-" \n|/\-_)+(Vo",
                # basically convert it to base-length, and then index into the string
    J           # Join this list of characters to a single string

See this 05AB1E tip of mine (section How to compress large integers?) to understand why •D¾ì6ªβh§ζƶwāZ·ªrΣ∍kϪ#8ñ2• is 78542092356563376216422644276947767672388754200679396880402.

Try just this first step.

.B              # Split on newlines, but add trailing spaces to make all lines the same length
  .º            # Mirror the list of lines horizontally with overlap in the middle
                # (after which the result is output implicitly)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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