I haven't written anything for a long time. When I was in high school, I wrote everything in order to write my compositions. I was afraid that the number of words I wrote was not enough. Hehe gave me 20 points for the college entrance examination compositions. The gloomy Lesson told me: the more you fear, the more important the moment comes! Escaping is not a solution to the problem.
I have been in college for three years, and I have been studying programming for almost two years. I would like to sum up my experience and hope that you will not miss me! I hope you will give me some advice on this.
Learning programming is not just a language, but a language is just a tool (a lot of online things are commonplace ). Generally, a written program consists of two parts: Data Structure and algorithm.
Data structure is a rule specific to a language. It has a rule just like any game. There is no shortcut, so you can just take a look at it, practice more, and remember it. In practice, we can understand it more deeply and thoroughly.
Algorithms, that is, the functions or methods we usually use in programming. To make the program more robust, more readable, and more compact, some algorithms are generally encapsulated, this facilitates transplantation and testing. In fact, to the vulgar, algorithms are the methods we usually use to solve problems, but they are described in languages. Just write what you want, as long as it does not violate the rules of the game.
Learning programming, in fact, I think we have learned programming since school, And we are learning the essence of programming ------- mathematics. They learned almost the same way. When encountering a problem (of course, they finally solved the problem), first of all, we should analyze what problems must be solved first? List every problem, and break down these small problems one by one until they are resolved! Of course, we can also combine the two sides in the middle: What can we solve first? What cannot be solved? Try to move these problems closer to the center and solve them step by step. When an error occurs, we can start with the small problems and analyze them one by one to locate the problem and finally solve it. Mathematics is especially important in science and engineering because it affects our thinking virtually. No wonder where mathematics is going, and this society will not be able to enter it.
Now we have learned four types of programming models: process-oriented, Object-based, object-oriented, and generic. If we compare programming to a pile of blocks, the API functions provided by others are scattered and small blocks. Sometimes, in order to quickly accumulate what we want, we will pile up these small blocks into another shape. when we need them, we can just take them and use them. We don't need to pile them up again. This is the class.
Discover and solve the problem ------ test, because I have never learned to test, only a basic method is to follow the program and check where the program runs, the problem will always be discovered. The simplest way is to track the program running through input and output until it is found to be abnormal.
Source of progress ---- error. People often get more experience from failure. Programming is also true. When you run a program and encounter a certain error, you 'd better solve it on your own, because only in this way can you make more progress and never be afraid of detours, sometimes you learn more in a detour. When an error occurs, analyze the error prompt first. Generally, the IDE has the error prompt and the line in which the error appears. Although some instructions are not clear enough, analyze the context of the error line, it can also help you find the root cause of the error and check the error prompt. This will also help you find the error in the future.
Learning programming is a process of understanding that conforms to "theory → practice → innovation → re-theory → re-practice → re-innovation. Programming can also be regarded as a technology. For technology, we can only improve ourselves through practice. Sometimes we may encounter such a problem. When we learn a new software course, it is very difficult to read those books. Sometimes I read it once and don't know what it said, I think this is because of your lack of practice. When you have actually practiced those books, you may overhead them and read them again. "Oh, it turns out so, I went to read this book again. "Oh, no wonder." At this time, you may blame yourself. "Why didn't you see it? Well, it's so stupid, when an idiot asks you, "Is this course studious? ", I think you can tell it that this course is too simple and can be learned by normal people!
Application Programming on the system is basically the same as solving problems in our daily life. I think about it in my head and write it on paper, store the calculated data in the memory, write the calculation in the external memory, store the data in the external memory, and return the data in the memory to the external memory for use, once and again, the problem is solved.
The programming in and under the system has not been learned yet, so I dare not comment on it.
To be continued ......