We can all learn C language well.

Source: Internet
Author: User

Currently, the object-oriented language is in the ascendant, and the scripting language is surging. Compared with older new languages such as Java and python, C language is definitely an old generation. We all know that C language was born in the 60 or 70 s of the last century, and it is not as object-oriented as C ++ or Java. It is a process-oriented language. As a result, many people began to suspect that learning C language is still useful?

The vast majority of science and engineering majors in general universities offer C language courses. C language is a computer grade examination subject in China. It is aimed at passing the examination, and it is difficult for many people to avoid getting in touch with C. However, given the utilitarian idea of coping with exams, is there any market for C? The answer is clear. C is very important. Some foreign institutions publish the global computer language rankings every month/quarter/year. The C language has always been proud of all the major rankings. Since then, the language is surging and it is still difficult to shake C's position. Although C is so powerful and lacks many object-oriented features, its advantages cannot be replaced. For example, the efficiency of C and the ability to control the underlying layer. If you have carefully studied C and mastered its essence, you will have a more thorough understanding of it.

For many beginners of C, C is actually not studious. Because of its close connection with the underlying layer, it brings him closer to the machine's way of thinking in some places, not human. So the pointer becomes a challenge for C. In addition, C is especially flexible, and it always gives priority to default programmers, so it is relatively loose in terms of syntax requirements. This is very dangerous for those who are not competent, and some errors that may cause system crashes may be hidden here. So how should we learn C well? In fact, it is similar to learning any computer language, for example, reading books carefully and practicing on multiple computers. We will not talk about the common issues here. Let's talk about some features.

To maximize the advantages of C, we must deepen our understanding of the computer, because C is closely linked with the underlying layer, so you need to be familiar with the computer memory, cache, data encoding, representation, and many other details. Otherwise, some code with a little depth will make you confused. Let's take a simple example. Let's look at the program below. Do you understand the purpose of the program below?

If you don't understand it, you can run it on the computer. That's right. You will be surprised to find that the running result of this program is the output statement "A = 5;" "machine code" in the memory ". This is very subtle, because the pointer gives C the ability to access the memory, we can obtain the machine code 01 sequence from it. Of course, the running of this program requires conditions. After the development environment changes, 0040d788 may also change (this address is only the result of an experiment on my computer ), more in-depth code is still sleeping in the computer.

In addition, reading is required. A good book will guide you to learn the real skills as soon as possible, so that you can avoid mistakes. But there are too many books, so it is too easy for us to be dazzled. The most common C language book we see is Tan haoqiang's "C program design", which should now be published in version 3rd. The circulation is said to exceed 10 million (because many universities choose it as a teaching material ). I used this book since I went to school. It should be enough to help you with the second level of computer, but it is too elementary to learn the real skills. I personally do not recommend this book. Of course, if your major is not related to computer science, this book is suitable for you. Here I am talking about how to deal with students in the science class. Explanation of C language (version 5th), Jeri, USA
R. hanly and Elliot B. koffman. This is a best-selling classic textbook with detailed content and excellent examples. However, this book is intended for readers who write C Programs in Unix or Linux. Therefore, some system calls are not very easy for Chinese students. Therefore, learning is difficult. Comparatively speaking, the C programming languages written by kernighan and Ritchie are more suitable for Chinese students to read. This is also a world-renowned C language book. Interested readers may wish to read it.

Teacher Li zhaoheng and I have also jointly compiled and published a C-language book "A Journey to understanding C Language", which has relatively loose requirements on readers, beginners and readers who have a certain degree of C can learn from the book. This book has been honed and is recommended by eight well-known experts in the industry upon completion, among them, the former Chief Engineer of Xi'an aviation Computing Technology Research Institute of China Aviation Industry, executive director of Shaanxi Software Industry Association, and researcher Wu guangmao, a doctoral advisor of northwestern Institute of Technology, is pleased to give a preface to this book. I believe this book can be a very good reference book for students to learn C language. In addition, as an improvement and expansion reading, Lin ruihe and Han Yongquan wrote "high quality programming-C/C ++ language", which will be a very good choice, this is a rare and excellent computer book written by Chinese people.

I hope everyone can learn the C language well. You are welcome to share your thoughts on the problems encountered during the C learning process with me. Of course, I do not recommend that you directly drop the programming assignments assigned by the school to the base camp teacher. A few students post a large segment of C program programming questions on the message board, and then directly hope that the base camp teacher will help him complete his homework. We hope that you will have more brains and hands-on work, and cherish the valuable opportunities for communication with instructors in the base camp. During the school training Mr. Sun Yat-Sen left for Sun Yat-sen University, there was a "careful thinking and interrogation". I believe that "questioning" is a reflection of a person's personal qualities.

========================================================== ====

Recommended to the students I write a good book learning data structure and algorithm "C ++ Data Structure Principle and classical problem solving" http://product.dangdang.com/product.aspx? Product_id = 20385620

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.