Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Aug 9th, 2005, 8:32 PM   #11
iignotus
Professional Programmer
 
iignotus's Avatar
 
Join Date: Apr 2005
Location: Nowhere Special
Posts: 466
Rep Power: 4 iignotus is on a distinguished road
Send a message via AIM to iignotus
Quote:
and well designed language
lolololol hahaha LMAO

Love perl by the way. As for what language you should use, perl is better if you really have to do some crazy dirty work in collecting data for your webpage. Otherwise, go with php.
__________________
% rc4 hexkey < input > output
#define S ,t=s[i],s[i]=s[j],s[j]=t /* rc4 hexkey <file */
unsigned char k[256],s[256],i,j,t;main(c,v,e)char**v;{++v;while(++i)s[ 
i]=i;for(c=0;*(*v)++;k[c++]=e)sscanf((*v)++-1,"%2x",&e);while(j+=s[i]
+k[i%c]S,++i);for(j=0;c=~getchar();putchar(~c^s[t+=s[i]]))j+=s[++i]S;}
iignotus is offline   Reply With Quote
Old Aug 10th, 2005, 5:42 AM   #12
prolog
Programmer
 
Join Date: Jul 2005
Location: Germany
Posts: 69
Rep Power: 4 prolog is on a distinguished road
Quote:
Originally Posted by iignotus
lolololol hahaha LMAO
Any reasons ?
__________________
-= C makes it easy to shoot yourself in the foot; C++ makes it harder, but when you do succeed, you will blow away your whole leg. =- Bjarne Stroustrup
prolog is offline   Reply With Quote
Old Aug 10th, 2005, 7:10 AM   #13
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
Perl is a well-designed language. Particularly when you consider that it began life as a mere report generator and was grown from there. Wall grew it with great good sense and a helluva smart attitude. Maybe it takes a certain kind of perception for the underpinnings to bubble through and draw notice.

That said, I prefer PHP currently. In my case, the reasons are simple. I'm new at PHP. Because of its strong C antecedents, I can search the manual for a function using the C function name as a starting point. I not only very often find it (though one has to be aware it won't be an identical twin), I often find in the same area an even better solution.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote
Old Aug 10th, 2005, 12:06 PM   #14
prolog
Programmer
 
Join Date: Jul 2005
Location: Germany
Posts: 69
Rep Power: 4 prolog is on a distinguished road
Hi,

@DaWei there are several pitfalls especially when your roots lie in C. I stumbled over this one a time ago. The handling of eof during file-io-operations in php. In C the eof-flag is set AFTER you tryed to read beyond the end of the file. In PHP this is not the case. It recognizes the end of file BEFORE you attempt to read beyond it. I was very confused about that. The syntax is so alike that i simply forgot for a moment that i was coding in php.

But i believe that the php-reference warns c-programmers about that.

This has nothing to do with my vote..... just wanted to mention that.
__________________
-= C makes it easy to shoot yourself in the foot; C++ makes it harder, but when you do succeed, you will blow away your whole leg. =- Bjarne Stroustrup
prolog is offline   Reply With Quote
Old Aug 10th, 2005, 12:42 PM   #15
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
Yeah, I'm aware of the drawbacks, thus my comment that they won't be identical twins. Pitfalls accompany any unwarranted assumptions. Another good example is "strtok". The warts that accompany the C/C++ version have been mostly burned away in the PHP version. It would be absolutely foolhardy to go with a label and not read the documentation. Apparently there are a lot of foolhardy people about, lol. My little comment goes more toward explaining why my learning curve for PHP was very steep (ability gained, versus time, I guess "steep" could be misconstrued), compared to my learning curve for Perl. Obviously, the Perl helped too, since there are antecedents there, also.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote
Old Aug 11th, 2005, 3:24 PM   #16
iignotus
Professional Programmer
 
iignotus's Avatar
 
Join Date: Apr 2005
Location: Nowhere Special
Posts: 466
Rep Power: 4 iignotus is on a distinguished road
Send a message via AIM to iignotus
Quote:
Any reasons ?
Because there's no unified way of doing things a lot of the time. However, that's why I like perl, because you can do anything a number of different ways -- it's just that it's a severely departed mindset from a lot of other languages.

To say that perl is a particularly well-designed language is a bit of a laugh, probably just because of all the things it's collected through the decades in order to remain viable, but to say that it's a bad language is also far from the truth.
__________________
% rc4 hexkey < input > output
#define S ,t=s[i],s[i]=s[j],s[j]=t /* rc4 hexkey <file */
unsigned char k[256],s[256],i,j,t;main(c,v,e)char**v;{++v;while(++i)s[ 
i]=i;for(c=0;*(*v)++;k[c++]=e)sscanf((*v)++-1,"%2x",&e);while(j+=s[i]
+k[i%c]S,++i);for(j=0;c=~getchar();putchar(~c^s[t+=s[i]]))j+=s[++i]S;}
iignotus is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 4:00 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC