Programming - My can of worms

Z

ZZs

Guest
Can someone recommend a python book to learn python?

I've obtained more than 100 python ebooks which contained a wide variety of lessons. I started with one book the other night and diligently read about 30 pages only to do the "hello world" classic first batch program. I was bored already. The only thing I thought up to create, and be helpful to me, was an audit app to verify services are up and running. I starred at the screen for about 5 minutes not knowing how to do this in python, and finally closed it thinking I can do this with BASH any time.

I know I need to learn more languages to build my Linux skills, but what makes python so great?

Currently I'm pretty good with BASH and know some PHP, especially in scripting, but starting to forget it. I seem to favour scripting languages, but I would like to learn more. Should I even bother with Python right now?

I read PHP has similarities to C, if so, maybe I should pursue C instead?
 


@arochester Awesome links! Thanks for sharing! :)

@ZZs - Should I even bother with Python right now?

Depends on what you're trying to accomplish. Do you need automate some tasks? Those can easily be done with a script. If you want to create an application, then Yes, learn Python (or any other programming language).

Keep in mind that there is a learning curve if you go with an OOP (Object Oriented Programming (language) ). Mostly, think of everything as an object. A string is an object, an integer is an object, every single "thing" is an object and it has methods and properties assigned to it. I went from procedural programming (Latest VB6) to OOP (VB.NET) where everything was driven by events (or procedures) to OOP and it was a bit of a learning curve. Once you get the concepts and what makes a language OOP (Inheritance, Polymorphism, Encapsulation and Abstraction) you'll be good to go.

I have looked at Python, and I think it's a wonderful language especially for those who have no programming experience. I do have a link to a Python tutorial, but it doesn't use the latest version of Python. I looked through it and it does a good job on teaching good programming practices; if you like I can find it and share it with you. I don't know if there is a big change between that versions of Python 2.7 or 2.8 and Python 3, so I can't say if it would be relevant. (I am sure someone who has experience with Python can chime in and let me and/or you know. I don't want to do the tutorial only to find out I have wasted my time. ;) )
 
I'm going to start with Python3 since I've seen it recommended to learn first so many times on this site. Really, I hoped someone that knows python and books would recommend one. I think its sometimes better to ask for recommendations for consideration. I have 130 python books so I probably have it.

As far as my question should I learn python, well I googled it and received a few answers.

I spent about 5 minutes on an internet tutorial today and that lesson looked like a php lesson only easier so I'm confident I can learn this fairly quickly.
 
Python is definitely worth learning. It is an extremely versatile and expressive language that can be used for a wide variety of tasks.

It is easy to learn and has a pretty comprehensive standard library. Plus there are literally thousands of additional modules available that extend the language, allowing you to incorporate all kinds of different functionality into your scripts. From GUI/widget libraries, to image manipulation libraries, to game engines, to statistical analysis/graphing libraries, to networking, cryptography, steganography etc. etc.

Once you get to grips with Python, you can achieve a lot with relatively little code - esp when compared to low level languages like C/C++. Also, despite being an interpreted, scripting language; it is still pretty fast!
And if you know C/C++, Python is also extensible. So you can create your own Python modules!

So the question is, what sort of things do you want to be able to do with Python? If we know what sort of things you want to do with Python, we can probably suggest some book/ebooks that are closely related to that topic.

Are you just looking for a primer on the language and its standard libraries? Or are there some specific things that you want to be able to do with Python?
 
If you really want to learn Python, what's going to help you most is coming up with a project you can work on. Just reading books, no matter how good, and doing exercises won't take you as far as something that you want to accomplish.

Like music? Got an MP3 player that's open (like using RockBox or something), write a Python application that will organize your music collection, and seamlessly move stuff from storage to music player, and so on. Yes, these things exist, and they may do all you want, but it's the journey, not the destination that counts most here.

You can also write a photo-organizing program, something like that. Anyway, the big thing is to find something you want to do, and then do it. To quote Guy Kawasaki, "Don't worry, be crappy".
 

Staff online

Members online


Top