PM Lord Badgerchops


Joined: Oct 15, 2010 Age: 23 Posts: 1437 Location: Southeastern United States
|
Posted: Thu Apr 12, 2012 9:17 am Post subject: Python |
|
|
I downloaded Python recently and I wanted to ask what would be some good uses for it. I'm new at programming so excuse my noobiness
Is this a good language to learn as a first language?
Are there any good bots that could be written to automate any menial software tasks? _________________ Who knows what evil lurks in the hearts of men? |
|
| Back to top |
|
Anomalia21 Butterfly


Joined: Jan 11, 2012 Posts: 10
|
Posted: Thu Apr 12, 2012 11:16 am Post subject: |
|
|
It's a good language to begin with as it has simple syntax and it's quite powerful. It's much slower than C or C++, but you can code in less time.
You can use it for general software, web applications and you can write with it non-critical parts of a larger program in C or C++, and infact this is a frequent use of it. |
|
| Back to top |
|
pete1061 Phoenix


Joined: Nov 13, 2011 Age: 43 Posts: 958 Location: Portland, OR
|
Posted: Fri Apr 13, 2012 9:49 am Post subject: |
|
|
Python is slow and different in structure from real languages.
Go with C/C++, or Java as a first language.
Python is the new "basic", it's a noob language. _________________ Your Aspie score: 172 of 200
Your neurotypical (non-autistic) score: 35 of 200
You are very likely an Aspie
Diagnosed in 2005 |
|
| Back to top |
|
UnLoser Phoenix


Joined: Mar 29, 2012 Posts: 623
|
Posted: Fri Apr 13, 2012 4:56 pm Post subject: |
|
|
| As a beginner programmer myself, my insight is limited, but here's what I think: Python could be considered a good language for beginners, given that it's easier to learn and work with than more typical languages like C. I started with Python as my first programming language, and was able to transition to C++ without much trouble. You'll still learn the foundations of programming with Python, and I don't see why Python has to be only for "noobs". It's a powerful language. |
|
| Back to top |
|
Ancalagon Computer Geek


Joined: Dec 26, 2007 Posts: 2411
|
Posted: Fri Apr 13, 2012 8:52 pm Post subject: |
|
|
Python is a very good beginner language. It is going to be somewhat slower than a language like C (which is more closely tied to the machine), but that's only execution speed, whereas not having to deal with some of the low-level details can help you code faster.
Programmer time is usually more valuable than processor time, so that's usually a good tradeoff. I've programmed in BASIC, and I've read other people's programs in BASIC, and python is very definitely not the new BASIC. _________________ "A dead thing can go with the stream, but only a living thing can go against it." --G. K. Chesterton |
|
| Back to top |
|
Burzum Indeed


Joined: Apr 27, 2011 Posts: 1205
|
Posted: Sat Apr 14, 2012 2:55 am Post subject: Re: Python |
|
|
| PM wrote: | | I downloaded Python recently and I wanted to ask what would be some good uses for it |
I mainly use it for small and simple things that aren't time critical in execution, or as a scripting language for large projects that are written in C++ or whatever.
| PM wrote: | | Is this a good language to learn as a first language? |
It's okay. You won't learn any lower level concepts though.
| pete1061 wrote: |
Python is the new "basic", it's a noob language. |
Explain. |
|
| Back to top |
|
AngelKnight Phoenix


Joined: May 04, 2011 Posts: 748 Location: This is not my home; I'm just passing through
|
Posted: Sat Apr 14, 2012 5:06 pm Post subject: Re: Python |
|
|
| Burzum wrote: | | PM wrote: | | Is this a good language to learn as a first language? |
It's okay. You won't learn any lower level concepts though. |
A number are missing; you don't end up dealing directly with "bare-metal" as much as you would with a language like C (or C++ written a certain way). There are still pretty good things in there that are arguably harder in C or C++ like proper higher-order functional programming and continuations-that-won't-break-your-mind (see Python generator functions).
There was an earlier statement about Python being a noob language. Only thing comes to mind to that is: everyone was a noob. May as well start somewhere. I agree that some somewheres are better than others, I guess I rank them differently. |
|
| Back to top |
|
kxmode Bible Student


Joined: Oct 15, 2007 Posts: 2664 Location: In your neighborhood, knocking on your door. :)
|
Posted: Sat Apr 14, 2012 5:20 pm Post subject: Re: Python |
|
|
| PM wrote: | I downloaded Python recently and I wanted to ask what would be some good uses for it. I'm new at programming so excuse my noobiness
Is this a good language to learn as a first language?
Are there any good bots that could be written to automate any menial software tasks? |
Python is great for IT people. It lets them create scripts to do really complex tasks. For example the script remotely checks for new database exports as zip files. The script acknowledges there's one. It then downloads the file, unpacks the zip, unpacks the tarball inside, test integrity of the database export, and then import it into final database.
If you have no need to do this sort of stuff I would recommend learning another language. Here's a list of what you should learn based on category.
Web
PHP - Quickly becoming an industry standard. It's free and there are countless resources online to help you learn. What makes PHP so important is many blog platforms - WordPress, Drupal, and so forth - are powered by this language.
ASP.NET - A robust language by Microsoft that is capable of creating more than web sites.
JAVA - A very powerful language by Oracle that is capable of more than web applications. You can also create games.
JQUERY - A modern JavaScipt platform that delivers JavaScript like performance on any website without needing to learn JavaScript.
Gaming
C++ / C# - If you want to learn how to program games these two are the industry standards.
Unity script - A new language developed by Unity. What makes this language so powerful is Unity can produce your games across a wide range of platforms (e.g. Apple, Microsoft, iPhones, Android, and so forth) with minimal effort.
If you would like to see a wide range of code snippets in various programming languages check out
http://snipt.net/ |
|
| Back to top |
|
FMX Velociraptor


Joined: Mar 17, 2012 Posts: 489
|
Posted: Sun Apr 15, 2012 6:50 pm Post subject: |
|
|
| Yes, I would definitely say Python is a good language to learn first - and you don't have to stop using it when you become more experienced either, because it is powerful and productive. If you later want to learn lower-level concepts then I'd recommend C, because it's basically "machine-independent assembler" - you have to deal with pointers all the time and that's an important concept to understand. If you just want to learn another language, not necessarily lower-level, then C# is a good one. Without wanting to start any "language holy wars", I would not recommend Java or PHP, especially as first languages. |
|
| Back to top |
|
RazorEddie Phoenix


Joined: Jan 19, 2012 Age: 42 Posts: 608
|
Posted: Sun Apr 15, 2012 7:24 pm Post subject: |
|
|
In my opinion it doesn't really matter what language you learn. The concepts are transferable between different languages. Python is relatively slow to execute but in most cases that does not matter. Unless you are doing heavy maths or data processing it will be fast enough. C/C++ is very powerful and you can pull clever tricks with pointers but you can also very easily shoot yourself in the foot. Many modern languages do their best to avoid the low level pointer stuff for this very reason. It adds extra overhead but if it makes your program more stable and easier to debug the tradeoff is well worth it. _________________ I stopped fighting my inner demons. We're on the same side now. |
|
| Back to top |
|
pete1061 Phoenix


Joined: Nov 13, 2011 Age: 43 Posts: 958 Location: Portland, OR
|
Posted: Sun Apr 15, 2012 9:57 pm Post subject: |
|
|
Of course, any language with the standard set of control structures are capable of very complex algorithms.
I just don't like python because it is a slow, interpreted language that doesn't follow much of the standard "c" type structure that so many of the other mainstream languages follow.
I like my curly brackets, that dang tab structure in python is awkward.
It really only good as a scripting language. I would never pay money for something written in python.
I personally recommend java as a good learning language. It's simpler than C++, but still useful in the professional world.
I still contend that Python is a noob language, though non-noobs may find legitimate complex uses for it.
But it still ranks on the same level with VB or Lua. _________________ Your Aspie score: 172 of 200
Your neurotypical (non-autistic) score: 35 of 200
You are very likely an Aspie
Diagnosed in 2005 |
|
| Back to top |
|
Ancalagon Computer Geek


Joined: Dec 26, 2007 Posts: 2411
|
Posted: Mon Apr 16, 2012 12:41 am Post subject: |
|
|
| pete1061 wrote: | I still contend that Python is a noob language, though non-noobs may find legitimate complex uses for it.
But it still ranks on the same level with VB or Lua. |
I think you're confusing 'close to the machine' or 'compiled' with 'serious'. There are some things compiled languages are going to be better at, and there are some things that interpreted languages are going to be better at. Sometimes you have to pick the right tool for the job. _________________ "A dead thing can go with the stream, but only a living thing can go against it." --G. K. Chesterton |
|
| Back to top |
|
Oodain big chief wulla bamboom alakaway


Joined: Jan 31, 2011 Age: 23 Posts: 5022 Location: in my own little tamarillo jungle,
|
Posted: Mon Apr 16, 2012 2:04 am Post subject: |
|
|
| Ancalagon wrote: | | pete1061 wrote: | I still contend that Python is a noob language, though non-noobs may find legitimate complex uses for it.
But it still ranks on the same level with VB or Lua. |
I think you're confusing 'close to the machine' or 'compiled' with 'serious'. There are some things compiled languages are going to be better at, and there are some things that interpreted languages are going to be better at. Sometimes you have to pick the right tool for the job. |
QFT _________________ //through chaos comes complexity//
the scent of the tamarillo is pungent and powerfull,
woe be to the nose who nears it.
|
|
| Back to top |
|
Evinceo Deinonychus


Joined: Apr 14, 2012 Posts: 386
|
Posted: Mon Apr 16, 2012 3:31 pm Post subject: |
|
|
What's python good for? Writing slow programs quickly. It's well suited to writing throwaway programs, or experimenting with algorithms. Python is a decent first language.
You can also use it for math homework, if you've got any. |
|
| Back to top |
|
FMX Velociraptor


Joined: Mar 17, 2012 Posts: 489
|
Posted: Mon Apr 16, 2012 8:31 pm Post subject: |
|
|
| Slow does not mean "throwaway". I actually used Python professionally in a company that at first insisted on using C++ for a certain internal system. Their reason was the same perception of performance: it must be fast. But how fast is "fast"? Well, it only needed to be run once per day and the C++ program ran in something like 30 seconds - but it was huge and complicated to maintain. Eventually it was completely rewritten in Python. The Python version took perhaps 60 seconds. Users didn't even realise we replaced it until we told them! But when the business found out they can now have changes made in a day instead of a week they were very happy to put up with the "slow" program. |
|
| Back to top |
|