Re: I couldn't understand why PHP is so popular. The PHP code looks so horrible compared with Java.
- From: "Rik Wasmus" <luiheidsgoeroe@xxxxxxxxxxx>
- Date: Tue, 29 Apr 2008 12:19:45 +0200
On Tue, 29 Apr 2008 11:55:29 +0200, Tim Streater <tim.streater@xxxxxxxxxxxx> wrote:
In article <4816ec6b$0$14354$e4fe514c@xxxxxxxxxxxxxx>,
Erwin Moller
<Since_humans_read_this_I_am_spammed_too_much@xxxxxxxxxxxxxxxx> wrote:
Rik Wasmus schreef:
> On Tue, 29 Apr 2008 08:00:47 +0200, tenxian <hi.steven.tu@xxxxxxxxx> wrote:
>> Could you put up with the horrible PHP code?
>
> No offcourse not, that's why we read this group.
>
> For comparison, here's some Perl:
> #!/usr/bin/perl -l
> s--@{[(gE^Ge)=~/[^g^e]/g]}[g^e]x((!!+~~g^e^g^e)<<pop).!gE-ge,
> s-[^ge^ge]-s,,,,s,@{[(g^';').(e^'?')]},(G^'/').(E^'|')^Ge,ge,
> print,s,(?<=/[^g^e])[^g^e][^g^e],$&^(G^'/').(E^'|')^gE,ge-ge
LOL.
The old I-hate-PERL-vibes are running up my spine again.
Thanks for reminding me why I code PHP these days. ;-)
Does that actually *do* anything? Or is it *really* just line-noise? I
copy pasted it into Terminal and all I got was a perl syntax error.
Well, offcourse it's deliberately obscure.
It creates triangles based on a number:
$test.pl 1
/\
/\/\
$test.pl 2
/\
/\/\
/\ /\
/\/\/\/\
$test.pl 3
/\
/\/\
/\ /\
/\/\/\/\
/\ /\
/\/\ /\/\
/\ /\ /\ /\
/\/\/\/\/\/\/\/\
$test.pl 4
/\
/\/\
/\ /\
/\/\/\/\
/\ /\
/\/\ /\/\
/\ /\ /\ /\
/\/\/\/\/\/\/\/\
/\ /\
/\/\ /\/\
/\ /\ /\ /\
/\/\/\/\ /\/\/\/\
/\ /\ /\ /\
/\/\ /\/\ /\/\ /\/\
/\ /\ /\ /\ /\ /\ /\ /\
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
--
Rik Wasmus
.
- Follow-Ups:
- References:
- I couldn't understand why PHP is so popular. The PHP code looks so horrible compared with Java.
- From: tenxian
- Re: I couldn't understand why PHP is so popular. The PHP code looks so horrible compared with Java.
- From: Rik Wasmus
- Re: I couldn't understand why PHP is so popular. The PHP code looks so horrible compared with Java.
- From: Erwin Moller
- Re: I couldn't understand why PHP is so popular. The PHP code looks so horrible compared with Java.
- From: Tim Streater
- I couldn't understand why PHP is so popular. The PHP code looks so horrible compared with Java.
- Prev by Date: Re: I couldn't understand why PHP is so popular. The PHP code looks so horrible compared with Java.
- Next by Date: SESSION error -> Your script possibly relies on a session side-effect which existed until PHP 4.2.3.
- Previous by thread: Re: I couldn't understand why PHP is so popular. The PHP code looks so horrible compared with Java.
- Next by thread: Re: I couldn't understand why PHP is so popular. The PHP code looks so horrible compared with Java.
- Index(es):