Python for beginner

A forum for general discussion of the Python programming language.

Python for beginner

Postby ngj35uk » Tue Apr 01, 2014 7:34 pm

hi
all i am new to programming i was going to pick python as a first language but a lot of people have been trying to talk me out of it. I was also thinking c# and php but cant make my mind up any advise would be greatful thank you
ngj35uk
 
Posts: 4
Joined: Tue May 21, 2013 7:35 pm

Re: Python for beginner

Postby stranac » Tue Apr 01, 2014 7:37 pm

Python is a great first language.
It's simple, readable and powerful.

Why are "a lot of people" trying to talk you out of learning it?
Did they mention any reasons why you should not?
Friendship is magic!

R.I.P. Tracy M. You will be missed.
User avatar
stranac
 
Posts: 1144
Joined: Thu Feb 07, 2013 3:42 pm

Re: Python for beginner

Postby ngj35uk » Tue Apr 01, 2014 7:47 pm

yes saying its out of date and i should be starting with c# but what i have seen python looks simple to pick up
ngj35uk
 
Posts: 4
Joined: Tue May 21, 2013 7:35 pm

Re: Python for beginner

Postby stranac » Tue Apr 01, 2014 7:59 pm

ngj35uk wrote:saying its out of date

If someone gives you a nonsense reason like that, I suggest you just ignore them...
Friendship is magic!

R.I.P. Tracy M. You will be missed.
User avatar
stranac
 
Posts: 1144
Joined: Thu Feb 07, 2013 3:42 pm

Re: Python for beginner

Postby DrakeMagi » Tue Apr 01, 2014 8:11 pm

I say python simple, safe, and batteries built in.
readablity is in the eye of the beholder. (I don't perfer the new style with underscore)(camelCase i like better)

I wouldn't use powerful to describe python.
python tends to be slow. in most cases it fast enough but i perfer more speed.

I use it as a playground. nothing more.

I avoid c# because of $M an always will.

nasm, c, c++, D, cython, python
Linux: won't find windows here.
Linux: the choice of a GNU generation.
https://github.com/DrakeMagi
DrakeMagi
 
Posts: 111
Joined: Sun May 12, 2013 8:36 pm

Re: Python for beginner

Postby metulburr » Tue Apr 01, 2014 8:24 pm

If you go to the c++ forum, chances are most of them will say you should start with c++. If you go to the java forums, chances are most of them will say you should start with java.

Some peoples theories are you should start with a complex language like c++ first and then learn a language like python. However some peoples theories are the opposite...starting with something like python and moving on to complex c++ later. I personally prefer the latter, but it is completely your choice.

I think python is the best choice for a first language. I started with c++ and moved to python, and now i do serious work in python and use c++ as my toy language. Mostly because it is too time consuming to write and maintain c++ as opposed to python.

saying its out of date

This, by the way, is complete rubbish. It sounds just like they are trying to manipulate you into ignoring python as a choice.

I am not a fan of Microsoft, thus i am not a fan of their language. So i have not yet done much in c#. People programming on Windows computers only and not caring about other platforms will use c#, VBscript , etc. You wont see many linux users programming in c#. Python is portable across all platforms.

EDIT:
python tends to be slow. in most cases it fast enough but i perfer more speed.

I use it as a playground. nothing more.

this makes python sounds like a slow toy language. Note this is only DrakeMagi's opinion. There is no point in attempting to increase speed if you do not need it, and you do not need speed to learn your first language. Python's wide variety of libraries makes it useful for quite a lot of different applications, from system monitoring, game development, to web site creation
http://en.wikipedia.org/wiki/List_of_Python_software
https://wiki.python.org/moin/OrganizationsUsingPython
New Users, Read This
OS Ubuntu 14.04, Arch Linux, Gentoo, Windows 7/8
https://github.com/metulburr
steam
User avatar
metulburr
 
Posts: 1469
Joined: Thu Feb 07, 2013 4:47 pm
Location: Elmira, NY

Re: Python for beginner

Postby Seanliu » Sun Apr 06, 2014 11:06 am

yes. As stracnac said, use python. The forced indentation makes the code easy to read, and if you are learning a first language, then the simplicity of the code should make it even easier. Here is an example.

C++:
Code: Select all
int main();
{
    printf(@"Hello World!");
}

Python:
Code: Select all
print('Hello World!")

Both of the codes above produce the output:
Code: Select all
Hello World!
The CoDeR!


--Sean Liu
User avatar
Seanliu
 
Posts: 29
Joined: Sun Mar 30, 2014 4:03 pm

Re: Python for beginner

Postby Mekire » Sun Apr 06, 2014 11:18 am

The idea that Python is a toy starter language that people should learn on before switching to a "real" language pisses me off no end. We hear the exact same arguments made against Python that were made against C when it was first created. As processing speed continues to increase the difference becomes (and will continue to become even more so) absolutely irrelevant.

Also the same people that espouse the idea that python is a starter language are the professors that then try to get their students to program ADTs in Python that are completely unnatural for the language. If you want to teach C, teach C; if you want to teach Python, you better actually know Python.

-Mek
User avatar
Mekire
 
Posts: 988
Joined: Thu Feb 07, 2013 11:33 pm
Location: Amakusa, Japan

Re: Python for beginner

Postby Kebap » Sun Apr 06, 2014 12:01 pm

Adding on to Seanlius comparison, here is "hello world" in Java:

Code: Select all
 public class Hello {
     public static void main(String []args) {
       System.out.println("Hello World");
     }
 }


Here are many more examples: http://c2.com/cgi/wiki?HelloWorldInMany ... gLanguages
Learn: How To Ask Questions The Smart Way
Join the #python-forum IRC channel on irc.freenode.net and chat with uns directly!
Kebap
 
Posts: 396
Joined: Thu Apr 04, 2013 1:17 pm
Location: Germany, Europe


Return to General Discussions

Who is online

Users browsing this forum: No registered users and 1 guest