How to become proficient in C language?
Many people know about C language. There may be many people who have studied it in college or even middle school. They may be familiar with it or only understand it. Those who can say that they are proficient should be able to cut off most people on the basis of the previous ones, so Some people want to know, how can I become proficient in C language?
1. First have a certain computer foundation and be prepared for subsequent improvements
is a person who has a professional background and directly learns C language , it is easy to master, relatively speaking there are fewer obstacles. If you are not a computer major, basic mechanism conversion will be a problem. Later, when you learn more difficult technical points such as pointers, the lack of some basic links will be exposed. Let’s take a simple example: shift operation. If you don’t understand decimal conversion, When it comes to binary, the rules of high eight bits and low eight bits, it is difficult to understand without some basic knowledge. The editor recommends a learning skirt for learning C/C [627, 012, 464]. Whether you are an expert or a novice, want to change careers or want to join the industry, you can learn about it and learn together! There is a lot of useful information and technical sharing in the skirt!
This is why many non-computer majors who want to learn programming have always recommended the principles of computer composition.
For computer majors, you can start learning C language directly. You need to choose a relatively good book. The current books with good reputation are also good. There is no need to buy them all to learn. It is the first time to learn. This book is enough. I recommend the C programming language and C primer plus. These two books have been used when getting started. I think it's pretty good.
2. Now that you are ready, how to learn and what strategies should be followed during the learning process?
Now that we have a certain foundation and the books are ready, some people will definitely say that it is also good to follow the videos to learn. Video learning is simple and clear, and the teacher in it explains it clearly. Why should we choose to focus on books? Many people like to watch martial arts TV series. People who have read the original works will always feel that something is missing when they watch the TV series. The video is a process of highly refining and concentrating knowledge, so it looks very simple and direct, and it seems easier to follow. study. After the language is processed and refined, people can understand it as soon as they hear it, but this process of processing and refining is not done by the people learning programming themselves.
Learning programming is essentially a process of establishing your own knowledge system. The establishment process requires a process of improving thinking and cognition. Things in books are more abstract and seem to give your brain more room for daydreams. It’s easy to let yourself use your brain. The point I want to emphasize here is not to say that it is wrong to watch videos to learn. You can watch them selectively. Based on books, if you encounter something you really don't understand, find the corresponding knowledge point, watch the video and learn it, and then return to the book. During this process, many people felt that I could understand it very clearly even after watching the video, but I couldn’t write anything without the video. The reason is that understanding clearly and understanding through practice are two different things. Practice more is the last word.
3. Master several common knowledge points
Data types, arrays, functions, pointers, structures, preprocessing, files, etc. piece. The real difficulty is concentrated in functions, pointers, and preprocessing does not seem difficult. At the bottom of many large-scale software, macros are used to implement many functions directly from the perspective of efficiency. Beginners should not think so much.
Pointers are the core of the entire C language. Callback functions and data structures all revolve around pointers. Many data structures are focused on learning in a special book. Essentially, they are a combination of pointers and structures to form various data structures, such as binary trees, trees, linked lists, etc.
For the understanding of pointers, a pointer is a variable, but this variable is slightly different from an ordinary variable. It stores an address. This address will point to a memory area. This area can store any value and can also continue. This is how the secondary pointer comes to store the address. The pointer must be initialized before use. Initialization is essentially to find a real memory area for this pointer. It sounds simple, but in actual use, beginners often make various mistakes, which is normal. Start digging the hole, and then slowly fill it until you understand what it means. This period may be more painful, but it is not that difficult to get through it and see again.
When you encounter a bottleneck in the learning process, you can look for the corresponding video and watch it, or you can leave a message to express your confusion. The knowledge points are limited to those few, and each one is missing. It will come to an end.
After mastering the general knowledge points, you can find some small projects to practice, such as Snake, Tetris and other games. The amount of code is relatively small, but it can also improve your coding ability and knowledge recognition from the side. degree of knowledge.
4. How to improve in depth
The difficulties in using C language to do projects mainly include three points: finding memory leaks, improving system performance, and building a reasonable framework.
Since C language pointers need to be initialized when used, they basically require memory application. If the memory is not released in time, continuous application will cause memory leaks. To find memory leaks, you need to write a hook function yourself to capture how many people have applied for memory, then grab the release function, grab the data, and compare it based on the address of the pointer to see if there is an address that only applied for memory but did not release it. After catching it, find the corresponding code and modify it directly.
There are generally two strategies for solving system performance. Re-examine the code logic and eliminate it bit by bit through debugging or printing. Doing this kind of work is tedious and requires the ability to grasp the specific overall situation. There is one Intuition for the code is included.
The requirements for building a framework are higher. The framework of the design module generally follows a high cohesion and low coupling strategy. However, in the actual development process, many calls may be made directly for convenience. It is considered a very high level of software development.
The content mentioned in this part may still feel relatively far away for beginners. It is basically something that programming veterans do. There will always be a process from novice to expert. Don't think that you have no hope because your current level is very poor. It all requires a process. A thousand miles begins with a single step.
As a beginner, you can take a look at what stage you are at now, how far the gap is, and how far you still have to go. If you know yourself and your enemy, you can fight a hundred battles without danger.
The above is the detailed content of How to become proficient in C language?. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Kimi: In just one sentence, in just ten seconds, a PPT will be ready. PPT is so annoying! To hold a meeting, you need to have a PPT; to write a weekly report, you need to have a PPT; to make an investment, you need to show a PPT; even when you accuse someone of cheating, you have to send a PPT. College is more like studying a PPT major. You watch PPT in class and do PPT after class. Perhaps, when Dennis Austin invented PPT 37 years ago, he did not expect that one day PPT would become so widespread. Talking about our hard experience of making PPT brings tears to our eyes. "It took three months to make a PPT of more than 20 pages, and I revised it dozens of times. I felt like vomiting when I saw the PPT." "At my peak, I did five PPTs a day, and even my breathing was PPT." If you have an impromptu meeting, you should do it

In the early morning of June 20th, Beijing time, CVPR2024, the top international computer vision conference held in Seattle, officially announced the best paper and other awards. This year, a total of 10 papers won awards, including 2 best papers and 2 best student papers. In addition, there were 2 best paper nominations and 4 best student paper nominations. The top conference in the field of computer vision (CV) is CVPR, which attracts a large number of research institutions and universities every year. According to statistics, a total of 11,532 papers were submitted this year, and 2,719 were accepted, with an acceptance rate of 23.6%. According to Georgia Institute of Technology’s statistical analysis of CVPR2024 data, from the perspective of research topics, the largest number of papers is image and video synthesis and generation (Imageandvideosyn

We know that LLM is trained on large-scale computer clusters using massive data. This site has introduced many methods and technologies used to assist and improve the LLM training process. Today, what we want to share is an article that goes deep into the underlying technology and introduces how to turn a bunch of "bare metals" without even an operating system into a computer cluster for training LLM. This article comes from Imbue, an AI startup that strives to achieve general intelligence by understanding how machines think. Of course, turning a bunch of "bare metal" without an operating system into a computer cluster for training LLM is not an easy process, full of exploration and trial and error, but Imbue finally successfully trained an LLM with 70 billion parameters. and in the process accumulate

Editor of the Machine Power Report: Yang Wen The wave of artificial intelligence represented by large models and AIGC has been quietly changing the way we live and work, but most people still don’t know how to use it. Therefore, we have launched the "AI in Use" column to introduce in detail how to use AI through intuitive, interesting and concise artificial intelligence use cases and stimulate everyone's thinking. We also welcome readers to submit innovative, hands-on use cases. Video link: https://mp.weixin.qq.com/s/2hX_i7li3RqdE4u016yGhQ Recently, the life vlog of a girl living alone became popular on Xiaohongshu. An illustration-style animation, coupled with a few healing words, can be easily picked up in just a few days.

Retrieval-augmented generation (RAG) is a technique that uses retrieval to boost language models. Specifically, before a language model generates an answer, it retrieves relevant information from an extensive document database and then uses this information to guide the generation process. This technology can greatly improve the accuracy and relevance of content, effectively alleviate the problem of hallucinations, increase the speed of knowledge update, and enhance the traceability of content generation. RAG is undoubtedly one of the most exciting areas of artificial intelligence research. For more details about RAG, please refer to the column article on this site "What are the new developments in RAG, which specializes in making up for the shortcomings of large models?" This review explains it clearly." But RAG is not perfect, and users often encounter some "pain points" when using it. Recently, NVIDIA’s advanced generative AI solution

When Sora failed to come out, OpenAI's opponents used their weapons to destroy the streets. If Sora is not open for use, it will really be stolen! Today, San Francisco startup LumaAI played a trump card and launched a new generation of AI video generation model DreamMachine. Free and available to everyone. According to reports, the model can generate high-quality, realistic videos based on simple text descriptions, with effects comparable to Sora. As soon as the news came out, a large number of users crowded into the official website to try it out. Although officials claim that the model can generate 120-frame video in just two minutes, many users have been waiting for hours on the official website due to a surge in visits. BarkleyDai, Luma’s head of product growth, had to comment on Discord

On July 24, Kuaishou video generation large model Keling AI announced that the basic model has been upgraded again and is fully open for internal testing. Kuaishou said that in order to allow more users to use Keling AI and better meet the different levels of usage needs of creators, from now on, on the basis of fully open internal testing, it will also officially launch a membership system for different categories of members. Provide corresponding exclusive functional services. At the same time, the basic model of Keling AI has also been upgraded again to further enhance the user experience. The basic model effect has been upgraded to further improve the user experience. Since its release more than a month ago, Keling AI has been upgraded and iterated many times. With the launch of this membership system, the basic model effect of Keling AI has once again undergone transformation. The first is that the picture quality has been significantly improved. The visual quality generated through the upgraded basic model

The matrix is difficult to understand, but it may be different if you look at it from another perspective. When learning mathematics, we are often frustrated by the difficulty and abstractness of the knowledge we learn; but sometimes, just by changing the perspective, we can find a simple and intuitive solution to the problem. For example, when we were learning the formula for the sum of squares (a+b)² when we were children, we may not understand why it is equal to a²+2ab+b². We only knew that it was written like this in the book and the teacher asked us to remember it like this; until one day we saw I saw this animated picture: It suddenly dawned on me that we can understand it from a geometric perspective! Now, this sense of enlightenment occurs again: a non-negative matrix can be equivalently converted into the corresponding directed graph! As shown in the figure below, the 3×3 matrix on the left can actually be
