What language do you choose to learn programming? Is it php, Python, or Ruby? _ Other Comprehensive

Source: Internet
Author: User
Tags php language minimalist design in python

To sum up simply a sentence:
1. If you want to help him find a job as soon as possible, make money, recommend PHP.
2. If you want him to be an efficient engineer, recommend Python.
3. If you want him to fall in love with his job, recommend Ruby.

Choice of Language:

The programming language is very important, do not think that they are all Turing equivalence, use the same. In fact, good language gives you something beyond imagination.

Here are some ideas:

1. Programmers time is far more valuable than machine time: Choose the most efficient language to develop, do not care too much about performance, if you can not develop something, then run faster and useless.

2. Elegant abstraction is better than simple piling up: This means that your code is the most concise and full of design, object-oriented, easy closure, everything is an expression, and so on, and the best abstraction is that the language itself can be layered, can write language, such as the ability of DSL power is an indicator.

3. A talented community is better than a difficult job: this language must have an active and talented community, and as long as the person who uses her, there is a sense of pride and elitism, and everyone in the community thinks they are better than others. Even if you are not so easy to recruit programmers, we don't all know that a talented programmer is better than 100 mediocre? Use this language to ensure that everyone in the team coding together is a master.

4. And most importantly, fun trumps everything: flexible, playful, always new to discover the magic language, only you can not imagine, no you can't, for a real hacker, this is the only reason to choose language, which is why Perl can survive for a long time, because she is hacker Hacker creation.

If you can read these views, I believe you can guess my choice:) Yes, Ruby is the most popular language I think is the most outstanding, the highest development efficiency, the most elegant and concise abstract ability, the most talented community (GitHub), and the greatest fun.

As a programmer, should be to choose the language of different ideas to learn, and of course to choose the most representative language, in the programming world, the mainstream thinking in fact, one is structured programming, one is functional programming, object-oriented is only structured programming a stage of evolution just, The other kinds of ideas are mostly the branches of these two.

The creativity of the community

Choosing a language depends on the temperament of the language community and what you want to do with him.

Mac can run so many languages, and a lot of people use git. But only Ruby users have developed a homebrew such a good package management system, the use of GitHub many features, the real user has become a potential repo contributors. I believe this is no coincidence. If the same conditions are in front of you, you have made a whole new thing and others have not, which means that you are more creative than others.

As a user of Python, I think Ruby's syntax is less important. But from the outside, the Ruby community has continued to export some of the ideas from technology to development in recent years, and there has been a growing number of cool projects, big and small, that have been born out of the Ruby community. Makes me think that the Ruby community is a very innovative community. So if you're learning to program to make a cool thing, then I strongly suggest you learn Ruby directly.

To compare from WEB development

For Web Development, these three languages are competent, but there are still a number of differences:

The 1.Ruby rails Framework is indeed a model for rapid development, but Ruby's syntax is too flexible and sometimes there are many different ways of writing the same process.

2.PHP is a veteran web scripting language, relatively mature compared to the other two. PHP is fast prototyping, but it's easy to get out of control, especially when the project is slightly larger.

3. For Python, because of its own minimalist design, the possible application of more, almost can relate to all aspects of it, the WEB is only one aspect of it, and there are more successful killer applications, Youtube is developed in Python, the server's various original Shell or Perl scripts, scientific calculations, game scripts, and even a Python masterpiece on a desktop client, such as Ulipad, Python is a good choice for beginners, in which the syntax is the most concise and clear, suitable for beginners to learn.

The introductory language should still choose a more rigorous language, such as Java,python, it is not easy to learn OO ideas and design patterns from the PHP language, and these are necessary for a good PHP programmer. This is not black PHP, each language has its own advantages, such as the introduction of PHP fast, you can increase the confidence of programming, understand the program that point after, you can analogy contact with other languages. Many programmers get started with PHP.
One of the phenomena in programming learning is that people who directly recommend Python do not have a thorough knowledge of Ruby. People who have studied Python and Ruby basically like Ruby.
What language is used specifically, not the only one. According to the scene is to be divided. A person needs to learn at least 3 languages:

1. One is working language, such as c++,java,php, these three languages, is the Internet's panacea, as long as it will, work is never worry, large companies will generally use, used to develop some large-scale projects.

2. One is your own language, such as Python,ruby, and of course, I also recommend Ruby. I also used Python, and then, because of my job needs, I reluctantly gave up Python, and finally, I was deeply in love with Ruby. And then no longer look back, for personal use, is to pay great attention to the development of efficiency, a language, at least 10 years, if the language of their choice, can surpass other languages in the development efficiency of one-tenth, then in 10 years this benefit is very large.

3. There is also a new language to use, do not need to go deep, but must understand, this helps to compare the deficiencies of different languages, so as not to become a frog in the well. such as Nodejs, scale and so on.

About Ruby

I think it's also a good choice to learn Ruby directly.
1. The rails framework would have brought Server,webrick. Looking at the Log to do development is very efficient.

2. The use of passenger is also absolutely convenient if it is to be deployed.

3.Views-tier template systems, ERB should be more beautiful and simpler than Python's. I've used Django before and I think it's too heavy.

4.Rails can make you constantly surprised the program can write this, ah, I first saw a 7.days.ago when startled.

5.Rails emphasizes a DSL, one that conforms to people's language habits and secondly I think it is a kind of subversion of programming language, we are not using a particular language (such as Ruby) to implement a function (as in C or Java to write a compiler), Instead, I can define a new language (similar to a lexical syntax builder like LEX,YACC) based on these languages. Look at the setting of the ROUTES.RB, how surprised, this is a procedure, is simply poetry. Beauty is not only in content, but also in form.

About Python

Python has a lot of advantages, such as:

1. Simple grammar, no need to compile. Python syntax is simple and efficient, one sentence "Life is too short, I use Python" what all explain, high efficiency is the characteristics of Python.

2. Powerful data structure. The default installed Python development environment already comes with a number of advanced data types, such as lists, tuples, dictionaries, collections, queues, and so on, which can be manipulated without further programming. Using these data types makes it easy to implement abstract mathematical concepts.

3. Force indent, so that the code will naturally appear organized.

4. Plug-in complete, you can complete most of the program design tasks.
Of course, there are a lot of things, you can also see the "Python Design Philosophy" this chapter.

Summary

There is no best language, only the most suitable language.
There is no bad language, only bad programmers.

No language is omnipotent, only one language is absolutely impossible.

What language is not important, the most important is efficiency: development efficiency and execution efficiency. PHP syntax is silly, not dazzling, but all learned C, JS, as and so on language, it is easy to get started, because there are a lot of grammatical overlap place. A lot of people don't look at PHP, say PHP too simple people, often because of the PHP itself is not deep enough to understand, in fact, the things in PHP in general people use very little, more than 5.3 of the characteristics also slowly let this language vivid, you more in-depth, the more you can find its strong and advantages.

Here are just a few examples of Php,python and Ruby that allow readers to better pick the language of learning.

Language is not inferior, Just follow your passion.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.