ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I've never used linux or programmed before but i'm planning on doing both soon. I was just wondering what the best and most popular programming language is for linux and also do you have to do it differently than on windows? For example, would i have to buy a linux specific programming book or would any programming book do?
Distribution: Fedora, Debian, OpenSuSE and Android
Posts: 1,820
Rep:
If you are new to programming and want to learn a language that helps you get the basics of coding/scripting down, I suggest PHP. It is designed for web applications but can be used for much more. Once you are comfortable with things like loop structure and function calls you can move on to harder languages. That is the path I have followed, except I started with GW Basic back in the day..
The beauty of Linux is that you can program in any language of your choice. Be it, C, C++, Java, Perl, Python, Ruby etc. The concept remains the same but a little change is in the ways of doing stuff
You can either buy books or read stuff on line. There is tonnes of info available on the net discussing to shreds how to program in Linux. Use Google and you will find a wealth of info.
Well, I would say C and C++ are probably the two most popular languages for linux programming. As far as learning it, learning how to program is C and C++ isn't much different from Linux to Windows. So long as you just use the standard libraries and none of the OS specific libs. There are tons of OS unspecific programming books at your local library or book store that'll help you out. There are also tons of OS specific ones if you want something that'll teach you the linux specific systems calls and what not.
Just another comment, I suggest not wasting time learning php, or any of those types of interpreted languages if your goal is acquire program skills.
People don't seam to understand the skill sets of mid/high level programming languages like C, C++, Java (not that javascript crap, real java) are completely different. If you truly want to learn to program you are better off just starting with something that'll allow you to learn the basic theories behind algorithms and learn all the basic programming concepts.
Pascal began life at least as a programming language for teaching programming. C and C++ are both standard languages, as long as you don't choose one made by a commercial company (or if you do, set the compiler to use 'ansi standards') C and C++ are cross platform insofar that the source code can be compiled on several platforms as long as you don't use stuff specific to a platform or OS. Good luck!
I would say to learn program structure, algorithims and linux at the same time, began shell scripting with ksh or bash or even csh (which has a similar c syntax), then once you master shell scripting and learn more linux move on to bigger things such as c or c++ .
good luck
Thanks alot for all your replies, i do already have a very limited knowledge of php already and i spose i'll try having a go at C since theres a dummies book on it
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.