Advertisement
T3RRYT3RR0R

Ungolfed rockets

Feb 23rd, 2020 (edited)
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Batch 1.16 KB | None | 0 0
  1. :# https://codegolf.stackexchange.com/a/199878/92319
  2. @Echo off&Setlocal EnableDelayedExpansion
  3.  Set "flagpipe=|"
  4.  Set /A booster_width=cone_interior=rocket_width=1,rocket_hieght=mast_offset=2,rocket_interior_width=3
  5.  For /l %%A in (2,1,%1)Do Set /A rocket_width+=1,mast_offset+=1,rocket_hieght+=2,booster_width+=2,rocket_interior_width+=2
  6.  Set line=!flagpipe!
  7.  Set Cone_offset=!rocket_width!
  8.  For /l %%A in (1,1,!mast_offset!)Do Set line= !line!
  9.  Echo(!line!
  10.  For /l %%A in (1,1,!rocket_width!)Do (
  11.   Set line=/
  12.   For /l %%B in (1,1,!Cone_offset!)Do Set "line= !line!"
  13.   For /l %%C in (1,1,!cone_interior!)Do Set "line=!line! "
  14.   Set line=!line!\
  15.   Echo(!line!
  16.   Set /A Cone_offset-=1,cone_interior+=2
  17.  )
  18.  Set rocket_corners=*
  19.  For /l %%A in (1,1,!rocket_interior_width!)Do Set rocket_corners=!rocket_corners!-
  20.  Set rocket_corners=!rocket_corners!*
  21.  Echo(!rocket_corners!
  22.  Set "line=!flagpipe! "
  23.  For /l %%A in (1,1,!rocket_width!)Do Set "line=!line!o "
  24.  Set "line=!line!!flagpipe!"
  25.  For /l %%A in (1,1,!rocket_hieght!)Do Echo(!line!
  26.  Echo(!rocket_corners!
  27.  Set line= /
  28.  For /l %%A in (1,1,!booster_width!)Do Set line=!line!_
  29.  Set line=!line!\
  30.  Echo(!line!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement