29
\$\begingroup\$

Problem

Recreate the UI from a torrent program

Given no input, output the following:

+----------+----------+----------+
|a.exe     |##########|seeding   |
+----------+----------+----------+
|b.exe 10% |#         |leeching  |
+----------+----------+----------+
|c.exe     |##########|seeding   |
+----------+----------+----------+
|d.exe 20% |##        |leeching  |
+----------+----------+----------+
|e.exe     |##########|seeding   |
+----------+----------+----------+
|f.exe 30% |###       |leeching  |
+----------+----------+----------+
|g.exe     |##########|seeding   |
+----------+----------+----------+
|h.exe 40% |####      |leeching  |
+----------+----------+----------+
|i.exe     |##########|seeding   |
+----------+----------+----------+
|j.exe 50% |#####     |leeching  |
+----------+----------+----------+
|k.exe     |##########|seeding   |
+----------+----------+----------+
|l.exe 60% |######    |leeching  |
+----------+----------+----------+
|m.exe     |##########|seeding   |
+----------+----------+----------+
|n.exe 70% |#######   |leeching  |
+----------+----------+----------+
|o.exe     |##########|seeding   |
+----------+----------+----------+
|p.exe 80% |########  |leeching  |
+----------+----------+----------+
|q.exe     |##########|seeding   |
+----------+----------+----------+
|r.exe 90% |######### |leeching  |
+----------+----------+----------+
|s.exe     |##########|seeding   |
+----------+----------+----------+
|t.exe     |##########|seeding   |
+----------+----------+----------+
|u.exe     |##########|seeding   |
+----------+----------+----------+
|v.exe     |##########|seeding   |
+----------+----------+----------+
|w.exe     |##########|seeding   |
+----------+----------+----------+
|x.exe     |##########|seeding   |
+----------+----------+----------+
|y.exe     |##########|seeding   |
+----------+----------+----------+
|z.exe     |##########|seeding   |
+----------+----------+----------+

progress for programs are:

b=10% d=20% f=30% h=40% j=50% l=60% n=70% p=80% r=90%

amount of #'s for leeching programs is progress/10

the rest are all seeding with full progress bars.

Rules

  • Leading and trailing newlines allowed.
  • Leading and trailing spaces allowed as long as it doesn't change shape of output.
  • stdout and functions for output allowed.
  • Shortest code in bytes win
\$\endgroup\$
4
  • 5
    \$\begingroup\$ You know downloading .exe from torrents is not the brightest thing to do, eh? \$\endgroup\$ Jun 27, 2017 at 6:57
  • 14
    \$\begingroup\$ @RobAu how else would I obtain f.exe can't find a copy of it anywhere else. \$\endgroup\$
    – LiefdeWen
    Jun 27, 2017 at 7:16
  • 9
    \$\begingroup\$ f.exe comes with f_readme.txt that says, "run as administrator". Seems legit. \$\endgroup\$ Jun 27, 2017 at 13:46
  • \$\begingroup\$ @RobAu I didn't know, I routinely download Linux distributions, that contain executables including some that install boot loaders, with torrents! \$\endgroup\$ Mar 3, 2019 at 0:20

31 Answers 31

11
\$\begingroup\$

Perl 5, 130 bytes

print$e=("+"."-"x10)x3 ."+
";printf"|$_.exe%4s |%-10s|%-9s |
$e",$|--&&$@++<9?("$@0%","#"x$@,leeching):("","#"x10,seeding)for a..z

Try it online!

I expect that there are a few bytes that can be golfed, but I've ran out of inspiration.

Short explanations:
$e contains the separation line (+----------+----------+----------+); its construction is straight forward (("+"."-"x10)x3 ."+\n").
Then, I loop over the characters from a to z:
Every time, print "|$_.exe%4s |%-10s|%-9s |\n$e; this is a standard printf with placeholders for strings (%s) and left-padded strings (%-9s).
if $|--&&$@++<9 is true ($| is a special variable that contains either 0 or 1, and decrementing it toggles its value), then the percentage is not 100%, and the three values in the print are "$@0%","#"x$@,leeching ($@0% is actually just $@ . "0" . "%" - remember that $@ was incremented earlier), otherwise, the three values are "","#"x10,seeding).

\$\endgroup\$
7
\$\begingroup\$

SOGL V0.12, 90 89 88 bytes

ēz{L┌* +3ΟQķ|;o".exe ”oēI»L*"% |”e» #*lLκ@*"┌5%8'Ω⅞█≡θ¹‘++++e'³>e2\+?X"⅓m÷Ko→∆)№(¤^▒«‘}o

Try it Here!

Explanation:

ē                                 push variable E (default = input, which default is 0) and increase it after (next ē call will result in 1, or next e call - 2)
 z{                               iterate over the lowercase alphabet
   L┌*                            push 10 dashes
       +                          push "+"
        3Ο                        encase 3 copies of the dashes in pluses
          Q                       output in a new line, without popping and without disabling auto-output
           ķ|                     output in a new line "|"
             ;o                   output the current iteration (the alphabet letter)
               ".exe ”o           output ".exe "
                       ē          push E and increase the variable after
                        I         increase it
                         5*       multiply by 5 (every 2 ē calls this gets called)
                           "% |”  push "% |"

e»                                  push (E)/2
   #*                               get that mant "#"s
     l                              get the length of that string
      Lκ                            push 10-length
        @*                          push that many spaces
          "..‘                      push "|leeching  |"
              ++++                  add all those strings on the stack together ((e+1)*5, "% |", "#..#", " .. ", "|leeching |") (done this way to leave the "+-+-+-+" on the stack)
                  e'³>              push e>19
                      e2\           push e divides by 2
                         +          add together (here works like OR)
                          ?         if that then
                           X          remove the added-together string
                            "..‘      push "    |##########|seeding   |"
                                }   END
                                 o  output POP (either the added string or full/seeding version)
implicitly output POP (since none of tTpP were called), which is the separator line
\$\endgroup\$
3
  • \$\begingroup\$ SOGL beats.... Charcoal?! \$\endgroup\$
    – Mr. Xcoder
    Jun 26, 2017 at 13:08
  • 1
    \$\begingroup\$ @Mr.Xcoder It's the most common scenario imo. \$\endgroup\$ Jun 26, 2017 at 14:26
  • \$\begingroup\$ Why the downvote? \$\endgroup\$
    – dzaima
    Jun 27, 2017 at 11:34
5
\$\begingroup\$

Charcoal, 98 85 83 bytes

F³B⁻³⁴×¹¹ι³M↘ .exeM⁶→×#χ|seeding⸿F²⁵C⁰¦²↗Fβ↓⁺ι-F⁹«J⁷⁺³×⁴ι⁺⁺ι¹0% |#P⁺× ⁹|leeching×#ι

I thought copying a template would save me a lot of code but it all seems to add up somehow, although I managed to save 13 bytes by using a single loop to fix the 9 leeching rows. Explanation:

F³B⁻³⁴×¹¹ι³             Make the top row of boxes
M↘ .exeM⁶→×#χ|seeding⸿  Print .exe, the 10 #s and seeding
F²⁵C⁰¦²                 Make 25 copies of the boxes
↗Fβ↓⁺ι-                 Put the letters in at the start
F⁹«                     For the 9 leeching files
   J⁷⁺³×⁴ι              Move the cursor to the percentage column
   ⁺⁺ι¹0% |#            Print the percentage and the first # of progress
   P⁺× ⁹|leeching       Erase the rest of the progress and change the status
   ×#ι                  Print the desired amount of progress

(Side note: I seem to have discovered a bug in Charcoal; | is an ASCII character, but it's also counted as an arrow for the purposes of Multiprint, so you can't Multiprint it.)

\$\endgroup\$
3
  • \$\begingroup\$ Not a bug, you can escape it if you want \$\endgroup\$
    – ASCII-only
    Jul 27, 2017 at 3:14
  • \$\begingroup\$ @ASCII-only Ah right, sadly the deverbosifier doesn't know that. \$\endgroup\$
    – Neil
    Jul 27, 2017 at 7:47
  • \$\begingroup\$ Oh true, thanks for reminding me \$\endgroup\$
    – ASCII-only
    Jul 27, 2017 at 10:35
5
\$\begingroup\$

Python 2, 182 177 bytes

Thanks to @officialaimm for shaving off 5 bytes by changing the format of the condition.

r=("+"+10*"-")*3+"+"
for i in range(26):z=i/2+1;print r+"\n|"+chr(97+i)+".exe "+["    |"+10*"#"+"|seeding ",`10*z`+"% |"+z*"#"+(10-z)*" "+"|leeching"][i%2and i<19]+"  |"
print r

Try it online!

\$\endgroup\$
4
  • 1
    \$\begingroup\$ 177 bytes \$\endgroup\$
    – 0xffcourse
    Jun 26, 2017 at 13:22
  • 1
    \$\begingroup\$ Nice! I've seen that a couple of times but didn't think of using it in this instance. May I update my answer with your solution? \$\endgroup\$
    – Fedone
    Jun 26, 2017 at 13:28
  • \$\begingroup\$ Of course, you can update it. ;) \$\endgroup\$
    – 0xffcourse
    Jun 26, 2017 at 13:29
  • \$\begingroup\$ 173 bytes \$\endgroup\$ Nov 20, 2017 at 15:38
3
\$\begingroup\$

Javascript, 232 230 228 226 bytes

(s='+----------'.repeat(3),p=0)=>[...'abcdefghijklmnopqrstuvwxyz'].map((c,i)=>(b=i%2,p=b?p+10:p,x=b&p<91,`${s}+'
|${c}.exe ${x?p+'%':'   '} |${'#'.repeat(x?p/10:10).padEnd(10)}|${x?'leeching':'seeding '}  |`)).join`
`+`
${s}+`
  • -2 Bytes thanks to @Stephen S - Using default function parameters
  • -2 Bytes thanks to OP - Replacing some spaces
  • -2 Bytes thanks to @Shaggy - Destructuring alphabet string

Demo

f=

(s='+----------'.repeat(3),p=0)=>[...'abcdefghijklmnopqrstuvwxyz'].map((c,i)=>(b=i%2,p=b?p+10:p,x=b&p<91,`${s}+'
|${c}.exe ${x?p+'%':'   '} |${'#'.repeat(x?p/10:10).padEnd(10)}|${x?'leeching':'seeding '}  |`)).join`
`+`
${s}+`

console.log(f());
.as-console-wrapper { max-height: 100% !important; top: 0; }

\$\endgroup\$
6
  • \$\begingroup\$ The last line is missing. Also, the submission and the Snippet differ; "leeching" is missing from the submission, for example. \$\endgroup\$
    – Shaggy
    Jun 26, 2017 at 12:22
  • \$\begingroup\$ @Shaggy Answer updated - Thanks for the follow \$\endgroup\$
    – Weedoze
    Jun 26, 2017 at 12:27
  • \$\begingroup\$ -2 bytes by moving s and p to default function parameters, removing the need for ()s around the function body: Fiddle \$\endgroup\$
    – Stephen
    Jun 26, 2017 at 12:42
  • \$\begingroup\$ I'm not sure but can't you change ${x?'leeching ':'seeding '}| to the following: ${x?'leeching':'seeding '} |? \$\endgroup\$
    – LiefdeWen
    Jun 26, 2017 at 12:50
  • \$\begingroup\$ @LiefdeWen You are right ! Thanks \$\endgroup\$
    – Weedoze
    Jun 26, 2017 at 12:54
2
\$\begingroup\$

Braingolf, 673 655 bytes

9..#+[#-]#+[#-]#+[#-]"+
|"!&@V"a.exe     |"!&@V9[##]"|seeding   |
"!&@v!&@v<1+>!&@V8##[# ]"|leeching  |
"!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@vv<<$_##>>!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@vv<<<$_##>>>!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@vv<<<<$_##>>>>!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@vv<<<<$_##>>>>!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@vv<<<<<$_##>>>>>!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@vv<<<<<<$_##>>>>>>!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@vv<<<<<<<$_##>>>>>>>!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@vv<<<<<<<<$_##>>>>>>>>!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@vv<<<<<<<<<$_##>>>>>>>>>!&@v!&@v<1+>!&@v!&@vv!&@v<1+>!&@v!&@vv!&@v<1+>!&@v!&@vv!&@v<1+>!&@v!&@vv!&@v<1+>!&@v!&@vv!&@v<1+>!&@v!&@vv$_!&@;

Try it online!

I've said it before and I'll say it again: Braingolf is bad at ASCII art.

At least this is only 1/3rd of the bytes it would take to actually hardcode the output

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

PHP, 179 bytes

without input

for($a=a;$x<53;++$x&1?:$a++)printf($x&1?"
|$a.exe%4s |%-10s|%-10s|
":str_pad("",34,"+----------"),($y=$x%4>2&$x<36?++$z:"")?$y."0%":"",str_repeat("#",$y?:10),$y?leeching:seeding);

Try it online!

PHP, 176 bytes

with input

for($a=a;$x<53;)printf($x&1?"
|$a.exe%4s |%-10s|%-10s|
":str_pad("",34,"+----------"),($y=strstr($argn,++$x&1?:$a++)[2])?$y."0%":"",str_repeat("#",$y?:10),$y?leeching:seeding);

Try it online!

\$\endgroup\$
1
  • \$\begingroup\$ Save 9 bytes from the first version: remove ++ from ++$x&1 (-2), use $y=++$x%4|$z>9?"":++$z."0%" as second printf parameter (-9) and insert $z before :10 (+2) \$\endgroup\$
    – Titus
    Apr 6, 2018 at 16:07
2
\$\begingroup\$

V, 107 bytes

¬azÓ./|&.exeò
ddÎAµ |±°#|seeding³ |
ÙÒ-4ñr+11lñddç^/P
jp4G9ñ8|R00%3l10r llRleeching4jñV{10g
çä/WylWl@"r#

Try it online!

Hexdump:

00000000: ac61 7ad3 2e2f 7c26 2e65 7865 f20a 6464  .az../|&.exe..dd
00000010: ce41 b520 7cb1 b023 7c73 6565 6469 6e67  .A. |..#|seeding
00000020: b320 7c0a d9d2 2d34 f172 2b31 316c f164  . |...-4.r+11l.d
00000030: 64e7 5e2f 500a 6a70 3447 39f1 387c 5230  d.^/P.jp4G9.8|R0
00000040: 3025 1b33 6c31 3072 206c 6c52 6c65 6563  0%.3l10r llRleec
00000050: 6869 6e67 1b34 6af1 567b 3130 6701 0ae7  hing.4j.V{10g...
00000060: e42f 5779 6c57 6c40 2272 23              ./WylWl@"r#
\$\endgroup\$
2
\$\begingroup\$

Japt, 121 bytes

;'++(-p10 +'+ ³
1
U+R+C£W=Yv ªY>20?10:Y¥1?1:V±1"|{X}.exe {4î hW>9?S:W+"0%"}|{10î h'#pW}|{10î hW<10?`äƒÊA`:`Ð:ˆg`}|"+R+U+R

Try it online!

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

Ruby, 141 bytes

puts s=(?++?-*10)*3+?+,(?a..?z).map{|c|["|#{c}.exe%4s |%-10s|%-9s |"%(c.ord%2>0||($.+=1)>9?["",?#*10,:seeding]:["#$.0%",?#*$.,:leeching]),s]}

Try it online!

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

Java (OpenJDK 8), 244 229 228 227 226 224 222 218 217 bytes

o->{String x="----------+",z="+"+x+x+x,s=z;for(int c=96,p;++c<123;s+=s.format("%n|%c.exe%4s |%-10s|%-10s|%n"+z,c,p>9?"":p+"0%","##########".substring(0,p),p>9?"seeding":"leeching"))p=(p=c/2-48)>9|c%2>0?10:p;return s;}

Try it online!

-2 bytes thanks to @KevinCruijssen!

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

Plain TeX, 306 bytes

\let\a\advance\def\b{+\r{\r-9-+}3\par}\def\s{\r~5|\r\#9\#|seeding\r~3|}\def\r#1#2{{\i0\loop#1\a\i1
\ifnum\i<#2\repeat}}\newcount\i\i`a\newcount\j\j1\tt\loop\b|\char\i.exe\ifodd\i\s\else\ifnum\i<`s\
\the\j0\%~|\r\#\j{\j-\j \a\j10 \r~\j}\a\j1|leeching\r~2|\else\s\fi\fi\endgraf\a\i1 \ifnum\i<`\{\repeat\b\bye

Ungolfed with some explanations:

\let\a\advance
\def\b{+\r{\r-9-+}3\par}%           The bar between rows: '+' + 3*(9*'-' + '-' + '+') + '\n'
\def\s{\r~5|\r\#9\#|seeding\r~3|}%  The common part for seeding lines, similar to \b
\def\r#1#2{{%                       Macro for repeating #1 #2 times
% Note the local grouping here which is needed for nested \loops and allows us to reuse the global \i
  \i0%
  \loop
    #1%
    \a\i1 %
    \ifnum\i<#2%
   \repeat%
}}%                                 
\newcount\i \i`a%                   Counter for ASCII values of letters, start with 'a'
\newcount\j \j1%                    Counter for percentages; shorter than modulo tricks
\tt
\loop
  \b|\char\i.exe%
  \ifodd\i
    \s%                             Odd lines are seeding lines
  \else
    \ifnum\i<`s\ %                  Even line up to 'r'
      \the\j0\%~|\r\#\j%            Print percentage and progress bar
      {\j-\j \a\j10 \r~\j}%         10-\j spaces after the progress bar
      \a\j1%
      |leeching\r~2|%
    \else
      \s%                           There's no \ifeven, hence the repetition here
    \fi
  \fi
  \endgraf%                         Print '\n'. \par doesn't work here, because \loop isn't a \long macro
  \a\i1
  \ifnum\i<`\{%                     Repeat until \j <= 'z'
\repeat
\b
\bye
\$\endgroup\$
1
\$\begingroup\$

Python 3, 255 bytes

I'm sure this can be golfed, updating soon:

e,l='.exe ',('+'+10*'-')*3+"+";print(l)
for i in zip(['|'+chr(z)+e+'    |'+"#"*10+'|seeding   |'if z%2or z>115else'|'+chr(z)+e+str((z-96)//2*10)+'% |'+(z-96)//2*"#"+(10-(z-96)//2)*" "+"|leeching  |"for z in range(97,123)],[l]*26):print(i[0],i[1],sep="\n")

Try it online!

\$\endgroup\$
4
  • \$\begingroup\$ instead of leeching | and seeding | , can't you change it into leeching and seeding +" |"? \$\endgroup\$
    – LiefdeWen
    Jun 26, 2017 at 15:40
  • \$\begingroup\$ @LiefdeWen I'm afraid that's 8 bytes longer... \$\endgroup\$
    – Mr. Xcoder
    Jun 26, 2017 at 18:56
  • \$\begingroup\$ Come on, "updating soon"? Anyway 246 bytes with list splat and and/or. \$\endgroup\$
    – DELETE_ME
    Apr 6, 2018 at 2:11
  • \$\begingroup\$ Also, //2*10 is just *5 and 10-(z-96)//2 is just 58-z//2. \$\endgroup\$
    – DELETE_ME
    Apr 6, 2018 at 2:13
1
\$\begingroup\$

Japt, 98 bytes

;27Æ4î+ ¬q-pU=10ÃíC¬£'|²¬q[X+".exe {W=Yu ©°T<U©T*U ?W+'%:P}"'#pW/UªU `äÊA Ð:g`¸g!W]m!hUî)q|})c ·

Doesn't work in the latest version due to a bug that messes up 4î+, q-p10, and q|, but it does work in commit f619c52. Test it online!

\$\endgroup\$
1
\$\begingroup\$

T-SQL, 238 bytes

DECLARE @ INT=1,@D CHAR(11)='+----------'L:PRINT @D+@D+@D+'+
|'+CHAR(@+96)+'.exe '+IIF(@%2=0AND
@<20,CONCAT(@/2,'0% |',REPLICATE('#',@/2),SPACE(10-@/2),'|leeching  |'),'    |##########|seeding   |')SET @+=1IF @<27GOTO L
PRINT @D+@D+@D+'+'

Procedural solution, formatted:

DECLARE @ INT=1, @D CHAR(11)='+----------'
L:
    PRINT @D + @D + @D + '+
|' + CHAR(@+96) + '.exe ' + 
    IIF(@%2=0 AND @<20, 
       CONCAT(@/2,'0% |',REPLICATE('#',@/2),SPACE(10-@/2),'|leeching  |'),
       '    |##########|seeding   |')
   SET @+=1
IF @<27 GOTO L
PRINT @D + @D + @D + '+'

Everything in the loop (up until the SET) is part of the same PRINT statement, including a line break inside the first string literal.

I'm working on a set-based solution (create and populate a table, then SELECT from it), but I'm not sure if its going to be smaller or not.

\$\endgroup\$
1
\$\begingroup\$

Java 8, 271 263 262 bytes

o->{String a="+----------",b=a+a+a+"+\n",r=b;for(int c=96,t;++c<123;r+="|"+(char)c+".exe "+(t>0?(c/2-48)+"0%":"   ")+" |##########".substring(0,t>0?c/2-46:12)+"         |".substring(t>0?c/2-49:9)+(t>0?"leeching":"seeding ")+"  |\n"+b)t=c<115&c%2<1?1:0;return r;}

All this trouble for nothing.. >.> ;)
(Shorter Java answer by @OliverGrégoire.)

Explanation:

Try it here.

o->{                       // Method with unused Object parameter and String return-type
  String a="+----------",b=a+a+a+"+\n",
                           //  Temp String "+----------+----------+----------+\n"
         r=b;              //  Result-String
  for(int c=96,t;++c<123   //  Loop from 'a' to 'z':
      ;                    //    After every iteration:
       r+=                 //     Append the result-String with:
         "|"               //      A literal "|"
         +(char)c          //      + the character
         +".exe "          //      + literal ".exe "
         +(t>0?            //      If the current character is below 's' and even unicode:
           (c/2-48)+"0%"   //       + the percentage
          :                //      Else:
           "   ")          //       + the spaces
         +" |##########"   //      + the progress bar
           .substring(0,   //       By using a substring from 0 to 
             t>0?          //        If the current character is below 's' and even unicode:
              c/2-46       //         'b' = 3; 'd' = 4; 'f' = 6; etc.
             :             //        Else:
              12)          //         12 (the entire progress bar)
         +"         |"     //      + spaces after the progress bar
           .substring(     //       By using a substring from
             t>0?          //        If the current character is below 's' and even unicode:
              c/2-49       //         'b' = 0; 'd' = 1; 'f' = 2; etc.
             :             //        Else:
              9)           //         9 (all the spaces)
         +(t>0?            //      If the current character is below 's' and even unicode:
           "leeching"      //       + literal "leeching"
          :                //      Else:
           "seeding ")     //       + literal "seeding "
         +"  |\n"          //      + literal "  |" + new-line
         +b)               //      + `b` ("+----------+----------+----------+\n")
  t=c<115&c%2<1?           //   If the current character is below 's' and even unicode:
     1                     //    `t` = 1
    :                      //   Else:
     0;                    //    `t` = 0
                           //  End of loop
  return r;                //  Return the result-String
}                          // End of method
\$\endgroup\$
3
  • \$\begingroup\$ Use a char instead of an int in the loop. It allows you to not cast it later on. t can be initialized and reinitialized to zero and += afterwards. It should still be shorter. \$\endgroup\$ Jun 27, 2017 at 13:18
  • \$\begingroup\$ @OlivierGrégoire It's actually 2 bytes longer. int & (char) & t=...; vs char & {t=1;t*=...;}. Unless I'm missing something. \$\endgroup\$ Jun 27, 2017 at 13:52
  • \$\begingroup\$ No you're not missing anything, that was my idea. I didn't take some other parts of your code in account. \$\endgroup\$ Jun 27, 2017 at 14:15
1
\$\begingroup\$

Charcoal, 154 149 143 130 103 bytes

A⁵δFβ«F³«+χ»+⸿A∨﹪δ²›δ⁹⁵θ|ι.exe⎇θ… ⁵⁺⁺ δ% ⁰|⎇θ…#χ⁺…#∕δχ… ⁻χ∕δχ⎇θ|seeding   |⸿↧|leeching  |⸿A⁺⁵δδ»F³«+χ»+

Try it online! (Link to verbose version.)

  • 27 bytes saves thanks to Neil's master Charcoaling techniques.
\$\endgroup\$
2
  • \$\begingroup\$ You can save a whole boatload of bytes by using \\r: Try it online!. Note that I've inserted dummy operations because I'm not getting any separators. \$\endgroup\$
    – Neil
    Jun 28, 2017 at 10:58
  • \$\begingroup\$ @Neil indeed, it seems that succesive printings are shorter than summing up chunks and printing the whole string. Not to mention the \r trick, I didn't know that. \$\endgroup\$
    – Charlie
    Jun 28, 2017 at 11:10
1
\$\begingroup\$

05AB1E, 120 bytes

AS".exe"«'A17×S9L‚ζJJðK€H©T*т%εD0Q_i'%«ëð3×}}‚ζεðýð«}®'#×T®-úí"leeching  seeding   "Tô®TQè)ζ'|ýε'|.ø}õ.ø'-T∍'+«3×'+ì¶.øý

Try it online!


There's way too much golfing to do here, will post explanation when I'm below 90 bytes.

\$\endgroup\$
1
\$\begingroup\$

Stax, 53 68 64 bytes

â"{≤╞c~£ÿτδ¬│∙}Dgoô₧»öÖ#9▌ó♂i◘ÿkùâGCå`è╙/♠Gδb,φW0EqΔ┘δth½àJZ¿l╦#

Run and debug it

Unpacked and ungolfed it looks like this.

'+'-A*+34:mQ
VaF
  '|p
  ".exe "+
  |;i^hA?X 
  $.0%+
  xA<Y*+G
  '#x*G
  `Qz/"D?d=T"`jy@G
  zP
  Q
}A(p'|p

Note that if you use the "Golf" button to remove whitespace and comments from the expanded solution, it incorrectly doubles the }. If you remove the extra character, it continues to work correctly.

\$\endgroup\$
1
\$\begingroup\$

Python 2, 172 170 162 bytes

-8 bytes thanks to Lynn

for i in range(2,28)+[id]:print('+'+'-'*10)*3+'+';a=i/2;b=i%2*(i<20);print('|'+'%-10s|'*3)%('%c.exe '%(95+i)+'%d0%%'%a*b,'#'*(a*b or 10),'sleeeedcihnign g'[b::2])

Try it online!

\$\endgroup\$
1
  • \$\begingroup\$ 162 and exit via crash: tio.run/… \$\endgroup\$
    – Lynn
    Apr 6, 2018 at 23:26
1
\$\begingroup\$

C (gcc), 217 211 bytes

-6 bytes thanks to ceilingcat

#define B"+----------"
f(p){for(char*a,*l=" bdfhjlnpr",i=97;puts(B B B"+"),i<'{';printf("|%c.exe %.*d%s |%-10.*s|%s  |\n",i++,!!a,p%10,a?"0%":"   ",p=a?a-l:10,"##########",a?"leeching":"seeding "))a=index(l,i);}

Try it online!

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

///, 264 bytes

/~/\/\///!/---~@/!!!-~$/@+@+@~</+
|~>/|
+~(/###~*/  ~}/|leeching*~[/.exe ~;/0% |~{/[**|(((#|seeding* ~]/>$</+$<a{]b[1;# ****}]c{]d[2;##****}]e{]f[3;( ***}]g{]h[4;(#***}]i{]j[5;(## **}]k{]l[6;((**}]m{]n[7;#((* }]o{]p[8;##((*}]q{]r[9;((( }]s{]t{]u{]v{]w{]x{]y{]z{>$+

Try it online!

Works by defining a bunch of replacements and using them to replace more characters than they are.

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

Mathematica, 274 bytes

a=Alphabet[];n=StringPadRight;o=ToString;Column@Join[Row/@Table[{g="+----------+----------+----------+\n","|"<>o@a[[i]]<>".exe ",If[EvenQ@i&&i<20,s=o[5i]<>"% ";k="|"<>Table["#",i/2];f="leeching";,k="|##########";f="seeding";s="    "];s,n[k,11]<>"|",n[f,10],"|"},{i,26}],{g}]
\$\endgroup\$
0
\$\begingroup\$

Bubblegum, 150 bytes

00000000: e007 3d00 8c5d 0015 8b71 ec14 6414 8031  ..=..]...q..d..1
00000010: 7fc3 2b24 3568 ca81 7ab5 363e c3b7 f500  ..+$5h..z.6>....
00000020: c926 d3f0 55d9 926f 75a8 f8d0 806f 1f12  .&..U..ou....o..
00000030: d71f b824 7e75 a7f2 544f 0364 ee5e 98be  ...$~u..TO.d.^..
00000040: a327 c36c 2ff1 8e6e df94 858e 82d0 d9da  .'.l/..n........
00000050: 77d6 fac6 5548 64aa 7a29 78fa 6886 3c85  w...UHd.z)x.h.<.
00000060: 0494 905e 74de a209 e927 42c8 418d 8250  ...^t....'B.A..P
00000070: ee39 c16b a4c2 9add 0b17 f8b0 9984 9aa8  .9.k............
00000080: defb 2875 31a9 c136 0ec2 6f28 9f8c 9990  ..(u1..6..o(....
00000090: 10d4 0000 0d0a                           ......

Try it online!

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

Perl6, 225 219

my&f={say ("+"~"-"x 10)x 3~"+"};my&g={f;my$b=$^c>9??"   "!!$c*10~"%";say "|$^a.exe $b |{'#'x$c}{' 'x(10-$c)}|$^d  |"};my \s="seeding ";for 1..9 {g chr(95+2*$_),10,s;g chr(96+2*$_),$_,"leeching"};g $_,10,s for "s".."z";f
\$\endgroup\$
0
\$\begingroup\$

Lua, 380 bytes

s=string.gsub
r=string.rep
function l(i)return".exe "..i.."0% |"..r("#",i)..r(" ",10-i).."|leeching  |\n"end
print((s(s("Z|aY|b"..l(1).."Z|cY|d"..l(2).."Z|eY|f"..l(3).."Z|gY|h"..l(4).."Z|iY|j"..l(5).."Z|kY|l"..l(6).."Z|mY|n"..l(7).."Z|oY|p"..l(8).."Z|qY|r"..l(9).."Z|sY|tY|uY|vY|wY|xY|yY|zY","Y",".exe     |##########|seeding   |\nZ"),"Z","+----------+----------+----------+\n")))

Uses gsub to create the row dividers and the seeding rows. l generates the leeching rows. Renaming gsub and rep saves more bytes.

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

Jstx, 126 bytes

►-○EO.♥/(:►+:1►+;+₧D0%4►|22♫♥φézï2♂bdfhjlnpr♀*U!↑)☺:♣<!,♂% |♀:2&₧#=-₧#/')▬►#◙')§► ◙21♫♠~√╫WσΓÇ2◙↓♫♥¿Ç~√₧#/►#:1♫♣~√▐┬╞¿:2◙►|41%

Try it online!

Explanation

►-          # Push literal -
○           # Push literal 9
E           # Push the second stack value the absolute value of the first stack value times.
O           # Collapse all stack values into a string, then push that string.
.           # Store the first stack value in the d register.
♥           # Push literal 3
/           # Enter an iteration block over the first stack value.
(           # Push the value contained in the d register.
:           # Push the sum of the second and first stack values.
►+          # Push literal +
:           # Push the sum of the second and first stack values.
1           # End an iteration block.
►+          # Push literal +
;           # Push the difference of the second and first stack values.
+           # Store the first stack value in the a register.
₧D          # Push literal abcdefghijklmnopqrstuvwxyz
0           # Enter an iteration block over the first stack value and push the iteration element register at the beginning of each loop.
%           # Push the value contained in the a register.
4           # Print the first stack value, then a newline.
►|          # Push literal |
2           # Print the first stack value.
2           # Print the first stack value.
♫♥φézï      # Push literal .exe 
2           # Print the first stack value.
♂bdfhjlnpr♀ # Push literal bdfhjlnpr
*           # Push the value contained in the iteration element register.
U           # Push a true if the second stack value contains the first stack value, else false.
!           # Push a copy of the first stack value.
↑           # Enter a conditional block if first stack value exactly equals true.
)           # Push the value contained in the iteration index register.
☺           # Push literal 1
:           # Push the sum of the second and first stack values.
♣           # Push literal 5
<           # Push the product of the second and first stack values.
!           # Push a copy of the first stack value.
,           # Store the first stack value in the b register.
♂% |♀       # Push literal % |
:           # Push the sum of the second and first stack values.
2           # Print the first stack value.
&           # Push the value contained in the b register.
₧#          # Push literal 10
=           # Push the quotient of the second and first stack values.
-           # Store the first stack value in the c register.
₧#          # Push literal 10
/           # Enter an iteration block over the first stack value.
'           # Push the value contained in the c register.
)           # Push the value contained in the iteration index register.
▬           # Enter a conditional block if the second stack value is less than the top stack value.
►#          # Push literal #
◙           # End a conditional block.
'           # Push the value contained in the c register.
)           # Push the value contained in the iteration index register.
§           # Enter a conditional block if the second stack value is greater than or equal to the top stack value.
►           # Push literal  
◙           # End a conditional block.
2           # Print the first stack value.
1           # End an iteration block.
♫♠~√╫WσΓÇ   # Push literal |leeching  
2           # Print the first stack value.
◙           # End a conditional block.
↓           # Enter a conditional block if first stack value exactly equals false.
♫♥¿Ç~√      # Push literal     |
₧#          # Push literal 10
/           # Enter an iteration block over the first stack value.
►#          # Push literal #
:           # Push the sum of the second and first stack values.
1           # End an iteration block.
♫♣~√▐┬╞¿    # Push literal |seeding   
:           # Push the sum of the second and first stack values.
2           # Print the first stack value.
◙           # End a conditional block.
►|          # Push literal |
4           # Print the first stack value, then a newline.
1           # End an iteration block.
%           # Push the value contained in the a register.
            # Implied println upon termination.

I'm sure this can get significantly shorter.

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

///, 226 bytes

/;/ "//:/$$$+//,/0% |//*/###//)/   //(/!
|//'/,*//&/.exe //$/+----------//"/ |leeching  |
:
|//!/&) |***#|seeding)|
:/:
|a(b&1,#)) ;c(d&2,##));e(f&3'))"g(h&4'#) ;i(j&5'##);k(l&6'*)"m(n&7'*# ;o(p&8'*##;q(r&9'**"s(t(u(v(w(x(y(z!

Try it online!

A bit more sophisticated approach to defining replacements. Try it interactively here!

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

Pascal (FPC), 294 286 266 263 bytes

const m='----------+';Q=#10'+'+m+m+m+#10;S='.exe     |##########|seeding   |'+Q;var i:word;begin write(Q);for i:=1to 9do write('|',chr(95+i*2),S,'|',chr(96+i*2),'.exe ',i,'0% |',StringOfChar('#',i),'|leeching  |':22-i,Q);for i:=115to 122do write('|',chr(i),S)end.

Try it online!

So... I ended up with both leading and trailing newline :D

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

PowerShell, 224 210 181 174 169 160 bytes

$l=("+"+"-"*10)*3+"+
"
0..25|%{"$l|$([char](97+$_)).exe "+("    |$("#"*10)|seeding ",("$(++$c/2)0% |{0,-10}|leeching"-f("#"*($c/2))))[$_%2-and$_-lt18]+"  |"}
$l

Try it online!

Now 64 bytes less terrible

Some Neat tricks: Combining a lot of "$(stuff)" to save on parens. We want only odd numbers which makes $_%2 = 1 so we don't need an -eq for it. Now uses list indexing instead of an if-else to save 5 bytes. Also gets rid of an `n for another byte. I couldn't get "$c`0%" to separate the var and zero so the current route was 1 byte shorter than gluing two strings together. Now with -f formatting.

\$\endgroup\$

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.