1
72 symbols pyth
Thu Nov 10 19:12:01 2016 Sait2000
.vCim-id64^964 2cCM"෺㯾棛矺榻窺榽痸秸燚竓㰄燋㯤莻⿯泹笀紂臯沸㓳脆㒹㰂狱燵羲涸㰊㛯侲覽⿽㧧诤柺瞲⸌ⶲ燯侲覰ⶲ壓埛"3^4 8
2
73 symbols pyth
Thu Nov 10 18:22:37 2016 Sait2000
.vCim-id64^964 2cCM"෺㯾棛矺榻窺榽痸秸燚竓㰄燋僫吆旯㺲泯盽緿耄泯㖷焃获㚾翵滴猂㖹⾾蟯侲覽⿽㧧诤柺瞲⸌ⶲ燯侲覰ⶲ壓埛"3^4 8
3
82 symbols pyth
Thu Nov 3 11:38:25 2016 Sait2000
h.vCim-id64^964 2cCM"妮啽ꄫ恫퀡病窀撢曅㍽傏㾚䒄㶛쵄藗錥痳啄↵쵛↾쏜뚨污謗욝Ꚗ规哫쥽ㆀ㳫攝稌䤰릻ⷶኑⰦ㋄ᙂ积穔硇⌣䝟窗ᔨ"3 65762
4
88 symbols pyth
Thu Nov 10 19:09:05 2016 Sait2000
Kjj\+m*\-hhlhdJmC.td;.Tv+"__import__('csv').reader"`(.z)_B"|-"VCJjj" | "N_B"|  "I~TZK;K
5
89 symbols pyth
Thu Nov 10 19:05:11 2016 Sait2000
Kjj\+m*\-hhlhdJmC.td;C[Fv+"__import__('csv').reader"`(.z)_B"|-"VCJjj" | "N_B"|  "I~TZK;K
6
90 symbols pyth
Sat Oct 29 16:05:16 2016 Sait2000
h.vCim-i%Vd[16=T64T)T=T5953cCM"厎濶齟䯺㒐䞥⢻쑅긅ㅐꍩῬ죸䘚ᮈ仄鯗銘揝궻鰡慞츭셸阐冑⽠헛ꛠꕩ胆嵵蜛隨옥庠싛礧듁䃟鳁騎⦋⋇믥颅ꔱ㫶瞖ㆬᣠ絬㮅䡼"3*T9
7
90 symbols pyth
Thu Nov 10 16:15:42 2016 Sait2000
Kjj\+m*\-hhlhdJmC.td;C[FvX_1"__import__('csv').reader()".z_B"|-"VCJjj" | "N_B"|  "I~TZK;K
8
91 symbols pyth
Sat Oct 29 08:12:34 2016 Sait2000
h.vCim-i+%hd16td64=T5953cm%Cd64"厎濶齟䯺㒐䞥⢻쑅긅ㅐꍩῬ죸䘚ᮈ仄鯗銘揝궻鰡慞츭셸阐冑⽠헛ꛠꕩ胆嵵蜛隨옥庠싛礧듁䃟鳁騎⦋⋇믥颅ꔱ㫶瞖ㆬᣠ絬㮅䡼"3*T9
9
93 symbols pyth
Thu Nov 10 16:37:57 2016 Sait2000
j.n[Kjj\+m*\-hhlhdJmC.td;C[FvX_1"__import__('csv').reader()".z_B"|-"m,W~TZjj" | "d_B"|  "KCJK
10
93 symbols pyth
Thu Nov 10 16:50:42 2016 Sait2000
h[
Kjj\+m*\-hhlhdJmC.td;C[FvX_1"__import__('csv').reader()".z_B"|-"m,
jj" | "d_B"|  "
W~TZKCJ
11
94 symbols pyth
Thu Nov 10 15:56:31 2016 Sait2000
Kjj\+m*\-hhlhdJmC.td;CvX_2"list(__import__('csv').reader())".z_B"|-"VCJjj" | "N_B"|  "I~TZK;K
12
97 symbols pyth
Thu Nov 10 15:47:56 2016 Sait2000
KX2"|--|"j\+m*\-hhlhdJmC.td;CvX_2"list(__import__('csv').reader())".zVCJX3"|    |"j" | "NI~TZK;K
13
98 symbols pyth
Thu Nov 10 15:27:41 2016 Sait2000
KX2"|--|"j\+m*\-hhlhdCJCmC.td;CvX_2"list(__import__('csv').reader())".zVJX3"|    |"j" | "NI~TZK;K
14
101 symbols pyth
Thu Nov 10 15:22:02 2016 Sait2000
K%"|-%s-|"j\+m*\-hhlhdCJCmC.td;Cv%"list(__import__('csv').reader(%s))"`.zVJ%"|  %s  |"j" | "NI~TZK;K
15
103 symbols pyth
Sat Oct 22 14:50:49 2016 Sait2000
K%"|-%s-|"j\+m*\-hhlhdCJCm.t.td;;Cv%"list(__import__('csv').reader(%s))"`.zVJ%"|  %s  |"j" | "NI~TZK;K
16
104 symbols pyth
Fri Oct 21 21:21:24 2016 Sait2000
K%"|-%s-|"j\+m*\-hhlhdCJCm.t.td;;Cv%"list(__import__('csv').reader(%s))"`.zVJ%"|  %s  |"j" | "NI!~hZK;K
17
105 symbols pyth
Fri Oct 21 21:20:23 2016 Sait2000
=Y%"|-%s-|"j\+m*\-hhlhdCJCm.t.td;;Cv%"list(__import__('csv').reader(%s))"`.zVJ%"|  %s  |"j" | "NI!~hZY;Y
18
107 symbols pyth
Fri Oct 21 21:18:28 2016 Sait2000
=Y%"|-%s-|"j\+m*\-hdmhlhdCJCm.t.td;;Cv%"list(__import__('csv').reader(%s))"`.zVJ%"|  %s  |"j" | "NI!~hZY;Y
19
109 symbols pyth
Fri Oct 21 21:16:00 2016 Sait2000
KmhlhdCJCm.t.td;;Cv%"list(__import__('csv').reader(%s))"`.z
=Y%"|-%s-|"j\+m*\-hdKVJ%"|  %s  |"j" | "NI!~hZY;Y
20
109 symbols pyth
Sat Oct 29 08:06:38 2016 Sait2000
 [
K%"|-%s-|"j\+m*\-hhlhdCJCm.t.td;;Cv%"list(__import__('csv').reader(%s))"`.zm,
%"|  %s  |"j" | "d &~TZ
KJ
K
21
111 symbols pyth
Fri Oct 21 21:13:07 2016 Sait2000
KmheSlMdCJv%"list(__import__('csv').reader(%s))"`.z
=Y%"|-%s-|"j\+m*\-hdKVCm.t.td;;CJ%"|  %s  |"j" | "NI!~hZY;Y
22
192 symbols ruby2.0
Fri Oct 21 19:02:25 2016 Sait2000
#!/usr/bin/ruby2.2 -rcsv
a=CSV.parse($<.read).map{|v|v.map &:to_s}
s=a.transpose.map{|c|c.map(&:size).max+1}
puts q="|-#{s.map{|v|?-*-~v}*?+}-|",a.map{|r|"|  #{r.zip(s).map{|v,w|v.ljust w}*'| '} |"}.insert(1,q),q
23
193 symbols ruby2.0
Fri Oct 21 19:01:53 2016 Sait2000
#!/usr/bin/ruby2.2 -rcsv
a=CSV.parse($<.read).map{|v|v.map &:to_s}
s=a.transpose.map{|c|c.map(&:size).max+1}
puts(q="|-#{s.map{|v|?-*-~v}*?+}-|",a.map{|r|"|  #{r.zip(s).map{|v,w|v.ljust w}*'| '} |"}.insert(1,q),q)
24
194 symbols ruby2.0
Sun Oct 2 07:07:33 2016 Sait2000
#!/usr/bin/ruby2.2 -rcsv
a=CSV.parse($<.read).map{|v|v.map &:to_s}
s=a.transpose.map{|c|c.map(&:size).max+1}
q="|-#{s.map{|v|?-*-~v}*?+}-|"
puts q,a.map{|r|"|  #{r.zip(s).map{|v,w|v.ljust w}*'| '} |"}.insert(1,q),q
25
223 symbols python2
Fri Oct 21 20:40:58 2016 Sait2000
import csv,sys
f=list(csv.reader(sys.stdin))
m=[1+max(map(len,c))for c in zip(*f)]
b='|-%s-|'%'+'.join(-~x*'-'for x in m)
print b
j=1
for t in f:print'|  %s |'%'| '.join(v.ljust(w)for v,w in zip(t,m))+j*('\n'+b);j=0
print b
26
291 symbols perl
Fri Feb 13 14:55:21 2015 vakorol
$j=0,@{$a[$i++]}=map{s/^"|\n$//g;s/""/"/g;$m[$j-1]=$l if($l=length)>$m[$j++];$_}split/"?,/,"$_\n"while<>;($t,$s,$g)=$y&&$y!=2&&$y<@a+2?(' ','','|'):qw/- - +/,$k=0,print("|$t".(join$g,map{($S=$s x$m[$k])||=$_;sprintf"$t%-$m[$k++]s$t",$S}@$_)."$t|\n"),++$y>@a+2?last:($s||$y==@a+2)&&redo for@a
27
308 symbols ruby2.0
Tue Sep 27 11:32:34 2016 doublehelix
require 'csv'
d=''
while s=gets do d+=s end
a=CSV.parse(d).map{ |v|v.map(&:to_s) }
@s=a.transpose.map{ |c|c.map(&:size).max }
def ps;"|-#{@s.map{ |v|'-'*(v+2) }.join('+')}-|\n"end
def pd(r);"|  #{r.zip(@s).map{ |v|v[0].ljust(v[1]) }.join(' | ')}  |\n"end
puts ps+pd(a[0])+ps+a[1..-1].map{ |r|pd(r) }.join+ps
28
322 symbols perl
Wed Jan 14 04:06:40 2015 g0ga
binmode(STDIN,':utf8');while(<>){my@r;s/"+/"/g;push@r,$3 while/(^|,)("*)(.*?)\2(?=,|$)/g;push@t,\@r if@r;$i=0;do{$l=2+length;$c[$i]=$l if$l> $c[$i];++$i}for@r}sub p{$r=@_?'| ':'|-';$j=0;for(@c){$r.=@_?" $_[$j]@{[' 'x($_-1-length$_[$j])]}|":'-'x$_.'+';++$j}$r=~s/(.).$/$1$1|/;print$r,"\n"}&p;p(@{shift@t});&p;p(@$_)for@t;&p
29
329 symbols perl
Wed Jan 14 04:05:49 2015 g0ga
binmode($_,':utf8')for(STDIN);while(<>){my@r;s/"+/"/g;push@r,$3 while/(^|,)("*)(.*?)\2(?=,|$)/g;push@t,\@r if@r;$i=0;do{$l=2+length;$c[$i]=$l if$l> $c[$i];++$i}for@r}sub p{$r=@_?'| ':'|-';$j=0;for(@c){$r.=@_?" $_[$j]@{[' 'x($_-1-length$_[$j])]}|":'-'x$_.'+';++$j}$r=~s/(.).$/$1$1|/;print$r,"\n"}&p;p(@{shift@t});&p;p(@$_)for@t;&p
30
336 symbols perl
Wed Jan 14 04:05:03 2015 g0ga
binmode($_,':utf8')for(STDIN,STDOUT);while(<>){my@r;s/"+/"/g;push@r,$3 while/(^|,)("*)(.*?)\2(?=,|$)/g;push@t,\@r if@r;$i=0;do{$l=2+length;$c[$i]=$l if$l> $c[$i];++$i}for@r}sub p{$r=@_?'| ':'|-';$j=0;for(@c){$r.=@_?" $_[$j]@{[' 'x($_-1-length$_[$j])]}|":'-'x$_.'+';++$j}$r=~s/(.).$/$1$1|/;print$r,"\n"}&p;p(@{shift@t});&p;p(@$_)for@t;&p
31
353 symbols perl
Tue Jan 13 22:59:01 2015 dmitry-tiger
while(<>){s/\n//g;s/,(?=,)/, /g;s/(?<!")"(?!")//g;s/""/"/g;my@F=split",";$#F=$#m if$#F<$#m;push@H,\@F;@c=map{length}@F;for($i=0;$i<=$#c;$i++){$m[$i]=$c[$i]if$m[$i]<$c[$i]}}sub p{print'|-'.join('+',(map{"-"x($_+2)}@m))."-|\n"}p;for$f(@H){$j=-1;p if$d++==1;use Encode;@a=map{$j++;sprintf"%-$m[$j]s",decode_utf8($_)}@$f;print"|  ".join(" | ",@a)."  |\n"}p;
32
353 symbols perl
Tue Jan 13 23:02:59 2015 dmitry-tiger
while(<>){s/\n//g;s/,(?=,)/, /g;s/(?<!")"(?!")//g;s/""/"/g;my@F=split",";$#F=$#m if$#F<$#m;push@H,\@F;@c=map{length}@F;for($i=0;$i<=$#c;$i++){$m[$i]=$c[$i]if$m[$i]<$c[$i]}}sub p{print'|-'.join('+',(map{"-"x($_+2)}@m))."-|\n"}p;for$f(@H){$j=-1;p if$d++==1;use Encode;@a=map{$j++;sprintf"%-$m[$j]s",decode_utf8($_)}@$f;print"|  ".join(" | ",@a)."  |\n"}p;
33
358 symbols php
Fri Jan 16 11:09:54 2015 BlackFan
<?=eval(gzinflate(base64_decode('bY9BT4QwEIX/CpnMoQ20wT2ZlHry4sWL3pBsFii7JZUaKGoU/7ttWWUPe5m2772Z+fpx0kYRgk1ZycmN+6NyzfROOn9O5On5/uGRUnpX5hXFWjZ2HpzPUoHt/yN4orMjQS1zgbrA1tc0pd9R7IPYF1j7GkT8KrGvStRxn1EDmV13u29VY1sVxp1d6pcMMfZ6+CTrNduaqfhBwyPyqN7UwRFgkK2xdEc5pBASEhYGfJprHyRosjxjN95ky8sA4iqf7rxW7KhqThbN1Y+h5RIS4Bssv+RI/jjYBS6HZAERhhJYkg3JrkjRD0xoJXjy8/Zf')));
34
361 symbols perl
Tue Jan 13 22:52:31 2015 dmitry-tiger
while(<>){s/\n//g;s/,(?=,)/, /g;s/(?<!")"(?!")//g;s/""/"/g;my@F=split(",",$_);$#F=$#m if$#F<$#m;push@H,\@F;@c=map{length}@F;for($i=0;$i<=$#c;$i++){$m[$i]=$c[$i]if$m[$i]<$c[$i]}}sub p{print '|-'.join ('+',(map{"-"x($_+2)} @m))."-|\n"}p;for$f(@H){$j=-1;p if$d++==1;use Encode;@a=map{$j++;sprintf"%-$m[$j]s",decode_utf8($_)}@$f;print"|  ".join(" | ",@a)."  |\n"}p;
35
367 symbols perl
Tue Jan 13 22:48:06 2015 dmitry-tiger
while (<>){s/[\r\n]//g;s/,(?=,)/, /g;s/(?<!")"(?!")//g;s/""/"/g;my @F=split(",",$_);$#F=$#m if$#F<$#m;push@H,\@F;@c=map{length}@F;for($i=0;$i<=$#c;$i++){$m[$i]=$c[$i]if$m[$i]<$c[$i]}}sub p{print '|-'.join ('+',(map{"-"x($_+2)} @m))."-|\n"}p;for$f(@H){$j=-1;p if$d++==1;use Encode;@a=map{$j++;sprintf"%-$m[$j]s",decode_utf8($_)}@$f;print"|  ".join(" | ",@a)."  |\n"}p;
36
370 symbols php
Fri Jan 16 10:37:57 2015 BlackFan
<?=eval(gzinflate(base64_decode('bY9Pb4MwDMW/CqssORYQsZ4mhdx26WWX7cZQBSG0IEYq/mzTSr/7EuhGD71Y8fOz3y9fx6rRjEEmy4Meevb69rx7IXqQiHQGlaSyH7q9Han+07pIXCCXyoztwECRgOK/SaKURGk6BpWMBFQxFLb6Pp1nsXZiHUNuqxPhJ4E6TaCaExrdsnEon/aFVqbQ7tx1SjaknW0f2TdbnsG67IAaPkN2+qSzgWGIwWLzt8TRR+eQOIXI+zG3RgZNEAXhI/FNOL23G3GXryqtFm9Jq6OB5u7HwHCJHvIVlt9yeH8c4Q0uR29C4Y4ynLwVySxIlsmbmcBIyMTlmv4L')));
37
377 symbols php
Tue Jan 13 23:15:17 2015 BlackFan
<?=eval(gzinflate(base64_decode("bY8/b4MwEMW/CkUnnS3AopkqGW9dunRpN4oiMCYBOTgC038h370G0iQDy8l+9+7e7772tVbkQR2O9odALqqdsj15e39+eaWUnkCmmehtt3Wy7D+dg/IzFEKaobUEJOVQXj9pnFFemY5ALWIOdQKlq0FAZ62ZtCaBwlWnneA3hSZLoZ4DtGrJYKunbamkKdW07dKlLqOdbYf8myzP8DbseNYiQbOZu1NHlVuCEYbLaLChDAPkoAWOEbJ+KJyPgA7jMHqkzI/Gj9bnq8h15bRkQ5XcG9Crp4JhAj1kN352j+H9Y0R3FzD0RuTTUuKPnn9FMguSY/JmJjACkZ8v6X8")));
38
378 symbols php
Tue Jan 13 22:51:34 2015 BlackFan
<?=eval(gzinflate(base64_decode("bY8/b4MwEMW/CkUnnS3AopkqGW9dunRpN4oiMCYBOTgC038h370G0iQDy8l+9+7e7772tVbkQR2O9odALqqdsj15e39+eaWUnkCmmehtt3Wy7D+dg/IzFEKaobUEJOVQXj9pnFFemY5ALWIOdQKlq0FAZ62ZtCaBwlWnneA3hSZLoZ4DtGrJYKunbamkKdW07dKlLqOdbYf8myzP8DbseNYiQbOZu1NHlVuCEYbLaLChDAPkoAWOEbJ+KJyPgA7jMHqkzI/Gj9bnq8h15bRkQ5XcG9Crp4JhAj1kN352j+H9Y0R3FzD0RuTTUuKPnn9FMguSY/JmJjACkZ8v6X8=")));
39
392 symbols python2
Fri Oct 21 19:24:26 2016 Sait2000
import csv,sys
f=list(csv.reader(sys.stdin))
a,s,r=len(f),len(f[0]),lambda i:[len(x[i])for x in f]
m=map(max,map(r,range(s)))
b='|-%s%%s-|'%('%s+'*(s-1))%tuple(map(lambda x:'-'*(x+2),m))
print b
for j in xrange(a):t=f[j];l=[[t[i],' '*(m[i]-len(t[i])+1)]for i in xrange(s)];print '|  %%s%%s|%s %%s%%s |'%(' %s%s|'*(s-2))%tuple([i for g in l for i in g]);sys.stdout.write((b+'\n')*(j%(a-1)==0))
40
408 symbols python2
Tue Jan 13 20:49:46 2015 beched
import csv,sys
f=list(csv.reader(sys.stdin))
a,s,r=len(f),len(f[0]),lambda i:[len(x[i])for x in f]
m=map(max,map(r,range(s)))
b='|-%s%%s-|'%('%s+'*(s-1))%tuple(map(lambda x:'-'*(x+2),m))
print b
for j in xrange(a):t=f[j];l=[[t[i],' '*(m[i]-len(t[i].decode('utf-8'))+1)]for i in xrange(s)];print '|  %%s%%s|%s %%s%%s |'%(' %s%s|'*(s-2))%tuple([i for g in l for i in g]);sys.stdout.write((b+'\n')*(j%(a-1)==0))
41
411 symbols python2
Tue Jan 13 20:34:49 2015 beched
import csv,sys
f=list(csv.reader(sys.stdin))
a,s,r=len(f),len(f[0]),lambda i:[len(x[i])for x in f]
m=map(max,map(lambda i:r(i),range(s)))
b='|-%s%%s-|'%('%s+'*(s-1))%tuple(map(lambda x:'-'*(x+2),m))
print b
for j in xrange(a):t=f[j];l=[[t[i],' '*(m[i]-len(t[i])+1)]for i in xrange(s)];print '|  %%s%%s|%s %%s%%s |'%(' %s%s|'*(s-2))%tuple([i for g in l for i in g]);sys.stdout.write(b+'\n' if j%(a-1)==0 else '')
42
412 symbols haskell
Sat Mar 14 07:06:35 2015 YoshikuniJujo
main=interact$unlines.f.(((i?).r)?).lines
(#)=replicate;e=length;c=concatMap;(?)=map;z=zipWith
r""=[""]
r(',':s)="":r s
r(c:s)=let h:t=r s in(c:h):t
g[x]=e?x
g(x:y)=z max(e?x)$g y
l m s="| "++init(c((' ':).(++" |"))$z a m s)++" |"
a n s=s++(n-e s)#' '
i('"':s)=q s
i s=s
q('"':'"':s)='"':q s
q('"':_)=""
q(c:d)=c:q d
p m="|-"++init(c((++"+").(#'-').(+2))m)++"-|"
f b@(s:t)=p m:l m s:p m:(l m)?t++[p m]where m=g b
43
427 symbols python2
Tue Jan 13 20:40:47 2015 beched
import csv,sys
f=list(csv.reader(sys.stdin))
a,s,r=len(f),len(f[0]),lambda i:[len(x[i])for x in f]
m=map(max,map(lambda i:r(i),range(s)))
b='|-%s%%s-|'%('%s+'*(s-1))%tuple(map(lambda x:'-'*(x+2),m))
print b
for j in xrange(a):t=f[j];l=[[t[i],' '*(m[i]-len(t[i].decode('utf-8'))+1)]for i in xrange(s)];print '|  %%s%%s|%s %%s%%s |'%(' %s%s|'*(s-2))%tuple([i for g in l for i in g]);sys.stdout.write(b+'\n' if j%(a-1)==0 else '')
44
462 symbols php
Tue Jan 13 19:23:39 2015 AndreyM
<?=eval(gzinflate(base64_decode("lVBNj4IwEP0rTTOHEhZ092S29rq/YPekhLClaA0UUuoGFP/7TgWNMcbESwMz7837qH5TbZyyJitTZWSda7Nh9Of7K1rQgEMhCl0qRptt8zmbtQ7XfixFZm3Ws4AXtVWZ3DIoSNYSaAOQq0S0zqYb5WT7x5zVFcM5snIh671xDCHzBP+r6xUwAip/i4EWcw56CTm+YRhAtQKd+Fl/ZQcjcuenuyX0+CLyeEcnZ/4ROu+mVIbtXbFIc4UZlbcAu8SfRmO6YKPMErqLIHT8dHpoyJz3PqFVjcocoxF9G1nhB0YpBR0iGuuqKb0SDXFrgphGA+VwEFA+zjmePVfjv+JbAXIRiB5HmU9JvHos6NoMhNw4IAOZPBAyrA2N4RAjiF5qfH9W4527qbWX7F2bnvw9d8dPHgQHruS2JljXPw==")));
45
517 symbols perl
Tue Jan 13 22:45:12 2015 dmitry-tiger
while (<>){
    s/[\r\n]//g;
    s/,(?=,)/, /g;
    s/(?<!")"(?!")//g;
    s/""/"/g;
    my @F=split(",",$_);
    $#F=$#m if $#F<$#m;
    push @H,\@F;
    @c=map{length}@F;
    for ($i=0;$i<=$#c;$i++){
       $m[$i] = $c[$i] if $m[$i] < $c[$i]
    }
}
sub p{
    print '|-'.join ('+',(map{"-"x($_+2)} @m))."-|\n";
}
p;
for $f (@H){
        $j=-1;
        p if $d++==1;
        use Encode;
        @a=map{$j++;sprintf"%-$m[$j]s",decode_utf8($_)}@$f;
        no bytes;
        print "|  ".join(" | ",@a)."  |\n";
}
p();
46
681 symbols php
Tue Jan 13 19:16:10 2015 AndreyM
<?php mb_internal_encoding("UTF-8");$f=file('php://stdin');$c=array();foreach($f as $s)$c[]=str_getcsv(trim($s));$d=count($c[0]);$m=array();$n=$m;for($i=0;$i<$d;$i++)$m[$i]=0;$y=count($c);for($j=0;$j<$y;$j++){for($i=0;$i<$d; $i++){$x=strlen(utf8_decode($c[$j][$i]));if($m[$i]<$x)$m[$i]=$x;}}for($i=0;$i<$d;$i++)$n[$i]=str_repeat("-",$m[$i]+2);$l="|-".implode("+",$n)."-|";$z=$l;for($i=0;$i<$d;$i++)$n[$i]=$c[0][$i].str_repeat(" ",$m[$i]-strlen(utf8_decode($c[0][$i])));$l.="\n|  ".implode(" | ",$n)."  |\n".$z."\n";for($j=1;$j<$y;$j++){for($i=0;$i<$d;$i++)$n[$i]=$c[$j][$i].str_repeat(" ",$m[$i]-strlen(utf8_decode($c[$j][$i])));$l.="|  ".implode(" | ",$n)."  |\n";}$l.=$z;echo $l;
47
702 symbols php
Tue Jan 13 19:12:02 2015 AndreyM
<?php mb_internal_encoding("UTF-8");$f=fopen('php://stdin','r');$c=array();while(($a=fgetcsv($f))&&$a!=array("")&&$a!=array())$c[]=$a;$d=count($c[0]);$m=array();$n=$m;for($i=0;$i<$d;$i++)$m[$i]=0;$y=count($c);for($j=0;$j<$y;$j++){for($i=0;$i<$d; $i++){$x=strlen(utf8_decode($c[$j][$i]));if($m[$i]<$x)$m[$i]=$x;}}for($i=0;$i<$d;$i++)$n[$i]=str_repeat("-",$m[$i]+2);$l="|-".implode("+",$n)."-|";$z=$l;for($i=0;$i<$d;$i++)$n[$i]=$c[0][$i].str_repeat(" ",$m[$i]-strlen(utf8_decode($c[0][$i])));$l.="\n|  ".implode(" | ",$n)."  |\n".$z."\n";for($j=1;$j<$y;$j++){for($i=0;$i<$d;$i++)$n[$i]=$c[$j][$i].str_repeat(" ",$m[$i]-strlen(utf8_decode($c[$j][$i])));$l.="|  ".implode(" | ",$n)."  |\n";}$l.=$z;echo $l;
48
940 symbols php
Tue Jan 13 18:31:16 2015 dmitry-tiger
<?php
$stdin = fopen('php://stdin', 'r');
$csv = array();
while (($arr = fgetcsv($stdin)) && $arr != array("") && $arr != array()) $csv[] = $arr;
$count = count($csv[0]);
$max = array();
for ($i = 0; $i < $count; $i++) $max[$i]=0;
for ($j = 0; $j < count($csv); $j++) {
    for ($i = 0; $i < $count; $i++) {
        $len = strlen($csv[$j][$i]);
        if ($max[$i] < $len) $max[$i] = $len;
    }
}
$new = array();
for ($i = 0; $i < $count; $i++) $new[$i] = str_repeat("-",$max[$i]+2);
$output = "|-".implode("+",$new)."-|";
$out1 = $output;
for ($i = 0; $i < $count; $i++) {
    $new[$i] = $csv[0][$i].str_repeat(" ",$max[$i]-strlen($csv[0][$i]));
}
$output .= "\n|  ".implode(" | ",$new)."  |\n".$out1."\n";
for ($j = 1; $j < count($csv); $j++) {
   for ($i = 0; $i < $count; $i++) $new[$i] = $csv[$j][$i].str_repeat(" ",$max[$i]-strlen($csv[$j][$i]));
   $output .= "|  ".implode(" | ",$new)."  |\n";
}
$output .= $out1;
echo $output;
?>
49
999 symbols php
Tue Jan 13 18:44:58 2015 AndreyM
<?php
mb_internal_encoding("UTF-8");
$stdin = fopen('php://stdin', 'r');
$csv = array();
while (($arr = fgetcsv($stdin)) && $arr != array("") && $arr != array()) $csv[] = $arr;
$count = count($csv[0]);
$max = array();
for ($i = 0; $i < $count; $i++) $max[$i]=0;
for ($j = 0; $j < count($csv); $j++) {
    for ($i = 0; $i < $count; $i++) {
        $len = strlen(utf8_decode($csv[$j][$i]));
        if ($max[$i] < $len) $max[$i] = $len;
    }
}
$new = array();
for ($i = 0; $i < $count; $i++) $new[$i] = str_repeat("-",$max[$i]+2);
$output = "|-".implode("+",$new)."-|";
$out1 = $output;
for ($i = 0; $i < $count; $i++) $new[$i] = $csv[0][$i].str_repeat(" ",$max[$i]-strlen(utf8_decode($csv[0][$i])));
$output .= "\n|  ".implode(" | ",$new)."  |\n".$out1."\n";
for ($j = 1; $j < count($csv); $j++) {
   for ($i = 0; $i < $count; $i++) $new[$i] = $csv[$j][$i].str_repeat(" ",$max[$i]-strlen(utf8_decode($csv[$j][$i])));
   $output .= "|  ".implode(" | ",$new)."  |\n";
}
$output .= $out1;
echo $output;