in reply to I want to know the problems in Perl
Both languages attempt to be as platform-independent as possible. Neither of these languages implement the actual operation of the features you ask about (except for the sendmail part, where it is an API issue). They provide a platform-independent API for performing the functionality you ask about, built on top of the various OSes. As such, 'better' is almost totally subjective, as it depends on how easily you understand one over the other. If you would like to see published results of the specific operations you ask about in terms of memory and CPU use, it can be summed up by the following linux command: 'cat /dev/null | more'
Corion gives the best answer (and, by the way, the answer that is almost always given when this question is asked here, which is often). However, having used both (but more Perl by far), I will offer the following additional insight, as from the phrasing of your question, I gather that you currently know neither all that well. I consider Perl to generally be the 'densest' language I have ever used. By 'densest', I mean that you can do the most in the fewest lines of code. It's highly symbol-intensive syntax is largely the reason for this. Python, in contrast, uses a more natural-language syntax. My experience has been that when people have to deal with non-trivial programs in either language, having little to no knowledge of them, that Python code is usually easier for them to figure out. However, this is hardly a good reason to choose one over the other. Beyond this, both have packages or built-in APIs that cover just about every generally-used feature or function available on the platforms where they run
Now, in the final analysis (keeping in mind you did not ask this question on PythonCharmers.org) The learning curve for Perl will most likely be a bit steeper than for Python, but is more than worth it. There are just so many non-trivial data manipulation tasks that can be done in just a couple of lines of Perl code that are used all the time, and have no parallel in any other language. That alone makes it worth using. And learning is also not that difficult. I found the Perl Cookbook to be a great learning tool to understand many of the aforementioned data manipulation techniques. Then, using Super Search here, you can find answers to just about anything you might want to know/do regarding things beyond the scope of the Cookbook.
Oh, and sorry for the sarcasm -- it comes with the territory...
fnord
|
|---|