Python or Perl?
Moderator: Forum Moderators
-
- Posts: 1549
- Joined: June 18th, 2009, 1:45 am
Python or Perl?
Mods: it'd be awesome if this was a poll. Well, I guess it doesn't have to. Your call.
Hey,
As you all may know, I've been trying to learn lua since January thus year. Lua is a light and very small language, so I think I've grasped the basics and have begun to understand some of the more complex things in Lua. So I kind of want look at another language while I continue studying lua. C++, python, and perl come to mind. C++ is probably too hard for me now, so I think I'll do either python or perl. And so you know my coding background, it's not much. Other than, I've only learned markup languages.
So, which one do you think is more worth learning? Your opinions please.
Hey,
As you all may know, I've been trying to learn lua since January thus year. Lua is a light and very small language, so I think I've grasped the basics and have begun to understand some of the more complex things in Lua. So I kind of want look at another language while I continue studying lua. C++, python, and perl come to mind. C++ is probably too hard for me now, so I think I'll do either python or perl. And so you know my coding background, it's not much. Other than, I've only learned markup languages.
So, which one do you think is more worth learning? Your opinions please.
Re: Python or Perl?
Touchy topic is touchy. The choice is entirely personal opinion. Neither one truly has any advantages over the other. They just do things differently.
This community is awesome, so I normally don't need to say this, but please, let's keep this civil.
This community is awesome, so I normally don't need to say this, but please, let's keep this civil.
- thespaceinvader
- Retired Art Director
- Posts: 8414
- Joined: August 25th, 2007, 10:12 am
- Location: Oxford, UK
- Contact:
Re: Python or Perl?
I like pythons, because they hiss. Perls are boring because I don't like knitwear. But I fail to see the comparison.
*whisperwhisperwhisper*
What do you mean 'programming language'?!
*whisperwhisperwhisper*
What do you mean 'programming language'?!
http://thespaceinvader.co.uk | http://thespaceinvader.deviantart.com
Back to work. Current projects: Catching up on commits. Picking Meridia back up. Sprite animations, many and varied.
Back to work. Current projects: Catching up on commits. Picking Meridia back up. Sprite animations, many and varied.
-
- Posts: 1549
- Joined: June 18th, 2009, 1:45 am
Re: Python or Perl?
Then let's keep it at this question: what things are each one good at?Gambit wrote:Touchy topic is touchy. The choice is entirely personal opinion. Neither one truly has any advantages over the other. They just do things differently.
Yes please.Gambit wrote:This community is awesome, so I normally don't need to say this, but please, let's keep this civil.
Then what the heck is C? Seems awfully boring to me. Let's all go get rubies!thespaceinvader wrote:I like pythons, because they hiss. Perls are boring because I don't like knitwear. But I fail to see the comparison.
Re: Python or Perl?
They're both pretty much equally good at the same things (everything). They're both generally the same speed too.monochromatic wrote: Then let's keep it at this question: what things are each one good at?
It really comes down to which syntax you prefer.
perl:
Code: Select all
if (1) {
print "Hello world";
}
else {
print "NOT POSSIBLE!";
}
Code: Select all
if 1 == 1:
print "Hello world"
else:
print "NOT POSSIBLE!"
-
- Posts: 1549
- Joined: June 18th, 2009, 1:45 am
Re: Python or Perl?
I see. From my inexperienced eye, python resembles lua alot in terms of syntax.Gambit wrote:They're both pretty much equally good at the same things (everything). They're both generally the same speed too.monochromatic wrote: Then let's keep it at this question: what things are each one good at?
It really comes down to which syntax you prefer.
perl:python:Code: Select all
if (1) { print "Hello world"; } else { print "NOT POSSIBLE!"; }
Code: Select all
if 1 == 1: print "Hello world" else: print "NOT POSSIBLE!"
Code: Select all
if 1 == 1 then
print("Hello world")
else
print("NOT POSSIBLE!")
end
Re: Python or Perl?
Python is a language that forces you to indent your code correctly. However, it's been a long time since I last used Python; and I never used Perl seriously, so I can't really give some advice.
Personally, I don't like Perl's syntax very much, but I know many people who love it.
Crend
Personally, I don't like Perl's syntax very much, but I know many people who love it.
Crend
UMC Story Images — Story images for your campaign!
- Elvish_Hunter
- Posts: 1576
- Joined: September 4th, 2009, 2:39 pm
- Location: Lintanir Forest...
Re: Python or Perl?
Did you knew that there is a programming language called Ruby? In some aspects, its syntax is even more similar (IMO) to Lua than Python - it uses also the nil values... On the other hand, it seems to have less libraries available than Python and Perl.monochromatic wrote:Let's all go get rubies!
Just to know, do you plan to make GUI programming in future? If yes, you may be interested in knowing that (for what I know) usually you can choose between four graphical libraries: Tk, Gtk, Qt and Wx. All of them are available for several languages: Python, Perl, Ruby, Lua, C++ and others. Just a note for the future.
Current maintainer of these add-ons, all on 1.16:
The Sojournings of Grog, Children of Dragons, A Rough Life, Wesnoth Lua Pack, The White Troll (co-author)
The Sojournings of Grog, Children of Dragons, A Rough Life, Wesnoth Lua Pack, The White Troll (co-author)
Re: Python or Perl?
Python is obviously the better language, on authority of Yoda
The Fires of Pride 0.3, a heavily story based campaign.
On hold while I try and finish my book
On hold while I try and finish my book
Re: Python or Perl?
Very funny link there Joram.
6 months and any code is tough already.
6 months and any code is tough already.
Re: Python or Perl?
Perl syntax is short, sweet and poetic.
Wesnoth Bestiary ( PREVIEW IT HERE )
Unit tree and stat browser
Canvas ( PREVIEW IT HERE )
Exp. map viewer
Unit tree and stat browser
Canvas ( PREVIEW IT HERE )
Exp. map viewer
-
- Posts: 427
- Joined: May 10th, 2011, 7:20 pm
Re: Python or Perl?
I love python. I used to do some Perl, but it got complicated, so I tried Python. And python has helped me out SO MUCH. I'm thinking about trying Perl again now...
Timshel
- Maiklas3000
- Posts: 532
- Joined: June 23rd, 2010, 10:43 am
Re: Python or Perl?
Perl is a nasty, evil language, great for quickly whipping up data manipulation utilities. However, you won't learn good coding style, which is what you need if you're a relative novice.
Re: Python or Perl?
I'm not sure if style == syntax, but in regards of the latter Perl is more similar to C++ and C than Python is. As far as nasty, and evil… eh.
- dipseydoodle
- Posts: 879
- Joined: September 16th, 2008, 10:26 pm
Re: Python or Perl?
The way I see it is this:
They're both scripting languages but, I see python as a more traditional language (like java, ruby etc...). Perl seems to me to be more simplistic and easier to understand.
They're both scripting languages but, I see python as a more traditional language (like java, ruby etc...). Perl seems to me to be more simplistic and easier to understand.