If you want to learn C/C++ together, you can add the penguin skirt six four three three nine two two two, there are various materials in the skirt to meet everyone, welcome to add the skirt
Ladies and gentlemen, to learn C well, you really only need one word, and that is "compose".
I. One Word of Truth
Learning C, and indeed all languages, is all about a hands-on approach - not hands-on beating, but hands-on programming. You have to familiarize yourself with the knowledge and understand it by writing programs. You can't get from beginner to proficient if you only learn and don't program, if you only read other people's programs and don't write them yourself. You know, in the computer world, people who are all talk and no practice are pretty much owed a beating. Imagine where you're hard at work programming and he's standing off to the side, babbling like a boss, giving you this opinion, that idea, even talking about how your programming will be, as if it's bullish, but just not programming a line of code. I guess when you come across such a person, there is only one action you can take, and that is to click "stomp".
Is it possible to learn C well with the word "coding"? Is it really that simple? No, it's not enough to just "make up", you need to "I make up".
(ii) I make up.
Please note the rhetoric. "I" made it up! The "I" is really just "you", the person learning C.
People should write more programs when learning C. For example, when learning about chains, write your own chains programs, or even write your own game programs like Tetris to practice. But there is a prerequisite, you must write all these programs yourself to have an effect, if you download the source code of so-and-so from the network, or copy the program of a classmate, any shamelessly say that they are written by themselves, then I can only shamelessly tell you, so made to develop the habit of stealing outside, there is no effect!
Some students will ask, so "personally" programming can always be proficient in C language, it, in fact, is still a little bit, just "coding" is not enough, just "I coding" is not enough to be proficient, in order to reach the peak of C language, you also need to "I coding coding".
(iii) I make up the edits.
The word "program" is repeated three times, where "three" means more, meaning you have to write more programs. Writing 10 lines of code in person is the same as not coding, writing 1000 lines of code in person is nowhere near enough, writing 10,000 lines of code in person is still sloppy, writing 100,000 lines of code in person makes you definitely a combatant among programmers.
At first glance at 100,000 lines of code, I guess some students will first lie straight down, then stand up with a twinkle in their eye - they think of a bad idea. "It's only 100,000 lines, easy! Nowadays, programming tools have code generation functions. Just drag and drop a few times with the mouse in VC, get an MFC window program, and the system automatically generates hundreds of lines of code. Get a few three-way controls in and a few thousand lines of code are generated! "
Once again, the prefix "compile" is "I", that is, the learner himself, and the code generated using the code generation tool is not written by the "learner"?
Either the top has a policy, or the bottom has a policy, 'don't use a code generator, then copy it and just enter the code as it is! "Hey, one can't be shameless to that extent! The 100,000 lines of code have to be done by "you" yourself, sprouted and rooted in your mind, and then entered line by line by yourself. It's not like it's some kind of performance task or image project, and deceiving people is ultimately only self-defeating.
II. Two attitudes
When people talk about C, one word often comes to mind, and that is "hard"! Scared ah, C language is really horrible, the legendary pointer is really too sharp, one inadvertent scratch the system, get a few dead reboots are too normal.
In fact, there is no need to worry so much. The great ancestor of this dynasty once said, "Defy the enemy in strategy, but value him in tactics. "
(i) Strategic defiance of the C language
Actually, C is just a normal language, don't make it too hard! Compared to Java, C is only a little more complex, a little longer, a little less library functions, a little more difficult to learn, a little more rudimentary compilation tools, a little more trouble with pointers, but not much else.
There is no need to talk about C. Just think of it as a normal language. You know, even if C is difficult, it's always easier to master than assembly language, easier to remember than machine language, and easier to master than English. So be confident! Everything in C is a paper tiger.
(ii) Tactical emphasis on C
We kept our spirits high in the face of C, though we were fearless. But really in the process of learning, or be sure to maintain a modest and cautious attitude, to stop arrogance, not because of a couple of tetris game program will be smug, think that I am the world's first, or even only traversed 10 lines of code, to the blog to go around cursing, everywhere "step" people's posts. No matter how much you have learned, as long as you have not yet started working, then the long march is only the first step, and there is still a long road waiting for you.
III. Three frameworks
Learning C language, "coding" is not the problem, the problem is "coding what", "how to coding", "coding how deep", the following to solve these problems.
(i) Meditation is not quiet
The process of learning is a long and tedious one, and learners must be prepared to suffer, to quiet their minds, to disappear from everyone's vision, and to endure a long process of being a programming student. You can't be a man until you've suffered! You will have a metamorphosis by the time you are back in everyone's face, and then all the pain will be turned into sweetness.
Mr. WEN Shui-on has a martial arts novel called "Please Lend Me Your Ladyship", which we borrow here as well. Not to borrow someone's girlfriend, of course, but to learn a little about the ownership's learning journey. The main character, Wei Qingqingqing, is a master when he comes out, and he softens the thousand and one kung fu moves in one move, but before its appearance, no one in the jianghu knows this character Wei Qingqingqing, because he is concentrating on practicing kung fu for ten years as one day, and it is this kind of practice when it is not known that has created the future master of Wen Rui'an novel.
Without getting into martial arts, here's an example of the IT version. On the other side of the ocean, before Microsoft's IE became popular, when the Internet was just starting, there was a browser called "Netscape" which occupied 99% of the market share, and Netscape was even more popular than Yi Zhongtian in the United States at that time. But do you know who developed this "Netscape" browser? Is a student, he is not obvious in the university, other students every day to consider soaking MM, but he is every day in addition to class is soaking computer room, is up also soak, down also soak, finally soak out the browser.
So, quietly, no matter how excited other students are showing off their so-and-so system, their so-and-so website, since you chose to learn C, take Wei Qingqingqing as an example, one day, you will become famous all over the world.
2. Not quiet
To learn C, you must not be impatient, you must take one step at a time, this is meditation. However, you can't be too silent about learning C. It's impossible to stay in a computer room and work behind closed doors thinking you'll create some amazing program and become the Bill Gates of China.
Learning is on our own, so most of the time we need to think and retreat on our own. But the power of one person is ultimately limited, and many times we need to use outside help. For example, you can consult your teacher if you don't understand something, discuss with each other if you don't understand something, etc. It's okay.
There are many students who run into difficulties and trouble when studying, so they meditate on it themselves - this is right - and still do not get results, so they deliberately avoid and ignore it - this is self-deception. Some students say that it is because no one can ask, ask the teacher, it seems that the university teacher always see the head, simply can not find; ask the network prawns, the network prawns are often not online, even if online, the face of the spill of the message also ignored, let alone reply; ask the classmates, do not mention too embarrassed! We're just classmates. Why ask him? Doesn't asking him mean you're inferior? No!
In fact, the discussion between classmates in the university is one of the most feasible practices, after all, a Wang Chong Yang does not have time to instruct the Seven Sons of Quan Zhen, the network prawns are more unreliable than the brothers in the cast, so in addition to their own more thinking is more discussion between classmates. Don't worry about being inferior by asking questions. There's an old saying from the ancestors that says "don't be ashamed to ask questions". What a nice Q. Use that!
Only by meditating can you learn better; only by not meditating can you learn faster.
(ii) Lack of depth
To learn C well, you must not be impatient and learn the knowledge in depth.
In fact, the above words would be extremely flimsy and extremely insightless. Who doesn't know that you have to study in depth, but your telling everyone exactly what content falls under in-depth study.
In fact, to be impatient is to learn knowledge is to float on the surface, without a deep understanding of expertise. This manifests itself in programming that just wants to write something supposedly pretty that can take the cake and ignores some of the underlying support programs.
Some students like to write nice programs, such as designing nice web pages, using so-and-so tools to develop so-and-so 'large' systems, etc. This is all human, of course. As Mr. Lu Xun said, articles are always written in the hope of having more readers, unless they are written for lovers. Programs are coded to always want to have more users, unless they are developed specifically for a loved one. The problem, however, is that it is not enough to write such programs, they are flawed.
These so-called programs often require only the application of the knowledge and do not require plumbing the knowledge itself, and many even incorporate a lot of fairly specialized content that is not suitable for beginners. MFC in VC, for example, is a typical tool to mislead beginners. Using MFC you can easily write DIAG interface programs or view document programs, which on the surface looks great, but is a curse for beginners! If you use VC to learn C++, most of your time will be spent on message handling, control handling, and reading a lot of view documentation and library descriptions, which will take up more time than it's worth. And most of the programming in VC++ is inserting code in certain locations, as for the C++ part the system implements it automatically, leaving you with pure C operations. Class, please note that you are learning C++, not VC class libraries, and not VC operations!
For example, if you use data structures, you have to write your own content about chains, queues and stacks, etc. You're learning, not working, so of course you have to use what you've written.
Another example is the memory allocation function in C, which is that malloc and free. The average person just calls it directly, but computer science students should not stop there, but think about the systematic implementation of these two functions and program to simulate memory allocation and release. Designing such a program will not only enhance your hands-on skills, but also deepen your understanding of computer knowledge, so why not do it all at once?
2. Not deep
In-depth study of C is extremely desirable, but we must also have some focus, not beard and all things in depth, specifically in two areas.
One of them. Some ranges of knowledge must not go too far.
There is some knowledge that is off the beaten track, neither basic, hard to stumble upon later in the workplace, and extremely difficult, and things like that are just fine to understand and not necessary to go into at all. For example, a certain student had a whim to write a beautiful input method software, so he painstakingly learned all about input methods, and also vainly tried to gaslight Tsinghua Ziguang and starve Sogou Pinyin, so he carefully studied the nooks and crannies of input methods. In fact, all of this knowledge is quite remote and is sufficient to understand, so there is absolutely no need to break the sand.
Secondly. Some interfaces or unnecessary features must not be too in-depth.
People write programs that are often accompanied by a lot of interactive interface design. In fact, there is a two-eight principle of programming, which means that writing 80% of the core content will consume 20% of your time, while the other 20% of the features will consume 80% of your time. In fact, as a C learning language, it's enough to write that 80% of the core functionality in depth, and spending 80% of your time trying to refine those 20% in depth is more than worth the effort!
So, it's best to practice with programs that have some basic, underlying implementation, without too many fancy images and interactive operations. Of course it is possible to design simple mini-games with a graphical interface, but at this point you should focus more on the design of the game itself rather than on the game's graphics style and animations.
Learn C. Do something and don't do anything.
(iii) Dull not boring
Learning is certainly a tedious process at the end of the world. When you design a program in a language, it appears to be a beautiful program, but behind the scenery is a black screen and long code. Programmers are professions that offer beauty to others and keep the boringness to themselves.
So, learning C means designing more boring, uninteresting examples. When flash programmers are showing images, C programmers have to learn the empty 0 and 1 image format; when Java programmers are designing websites, C programmers have to understand the abstract HTTP protocol; when .net programmers are using object hosting, C programmers always have to think about memory requests and releases; when C++ programmers are joyfully using STL libraries, C programmers have to build all the data structures themselves.
There are definitely not as many flowers on the way to learning C as there are in learning other languages, and this is a fact that every C enthusiast must accept.
2. Not withered
Actually, people need motivation, so why should other programmers be able to enjoy the reverence of MM and the admiration of their classmates through beautiful programs, while C programmers are left to communicate with computers in a world of zeros and ones. In fact, the process of learning C can be completely enjoyable.
When you know the basics, you can design some simple fun games, from snake to tetris, from bumper to bumper, from minesweeper to thunderbolt, and even plants vs. zombies and angry birds, and write some fun games with simplified interface.
It's boring because learning is not playful. It's not boring because it's about learning as much as it is about playing.
IV. Four notes
(i) Wrong view: C is inferior
Since C is often applied to some server programs without a nice interface, in the minds of some students, C programmers have become synonymous with IT folk. Similar to coal miners, living under the ground all day. And those Java programmers, .net programmers became white collar beauties.
(ii) Wrong view: C is superior
Contrary to the first case, some students believe that C is the language orthodoxy. As the saying goes: real programmers use C, smart programmers use delphi. Then the rest of the language is all a goddam brand of floating clouds, not worth mentioning. All other programmers, whether smart or stupid, are pirate waterworks.
(iii) Wrong opinion: C is a faithful lover.
There are three thousand weak waters and only one scoop. Some people are faithful in love, others go to be faithful in language, some, like Snape, love only one woman in their lives, others wish to follow suit and use only one language in their lives.
(iv) All talk and no action
The real word for learning C is "programming", but some students may argue, "Do I need to write such a simple program myself? ", "I know how to do this program just by looking at it", "Skip this program and just write the one that follows", "Don't waste your genius on such a small program", and so on and so forth.
The above is actually a typical case of "underestimation".
People often experience this when studying math in high school: when you look at it, you know it, but when you do it, you get it wrong. Computer programming is actually the same, how to look simple, anyone can say a ding three dao four to, but really on a practical, hands also shake, waist also bent, head also confused. Either I can't write a single line of code for half a day, or I can't compile it without getting an error, and I can't find out what the cause is.
So, here's a word of advice to all you "masters" out there, practice makes the best. It's a mule or a horse, pull it out for a spin. Please ask those so-called "masters" to try to do one or two assignments first, and only those who are really good at it will be the real masters, otherwise, just do the carpet programming honestly.
>>1、Using Photoshop to achieve the spring lettering effect2、P1801 Black BoxNOI Guide 2010 Improvement 063、Report White Paper on Big Data Industry Transactions Full Coverage of 16 Major Industries4、The Ten Most Commonly Used Algorithms by Data Scientists Official KDnuggets Survey5、KaiFu Lee China and US should lead AI revolution together Global cooperation needs to be strengthened