Thread code (8 answers)
Opened by pq at 2010-02-05 18:34

pq
 2011-06-19 16:04
#794 #794
User since
2009-03-02
341 Artikel
Admin

user image
1 zeile perl:
Code (perl): (dl )
lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala


2 zeilen code:
Code: (dl )
1
2
lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala
lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala lalala


perl-code:
Code (perl): (dl )
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use strict;
use warnings;

my %colors;

while(<DATA>)
{
  next unless($_=~/^\s*(\w+)\s*=\s*(.+)\s*$/);
  $colors{lc($1)}=$2;
}

my $name=shift(@ARGV);

if($name && $colors{lc($name)})
{ print $colors{lc($name)}."\n"; }
insert sig here

View full thread code