Chapter 129 Languages that can write operating systems
Lin Hong did not know at this moment that, in fact, the Windows operation interface of the Apple system should be released before Microsoft's Windows. It was after seeing Apple's Windows operating system that Microsoft urgently summoned people to develop it.
Later, Apple and Microsoft fought for many years for this matter. Unfortunately, Apple failed to win the lawsuit, because Apple was not the first to use the Windows system. The first to develop the Windows operating system was a company called Xerox, which was a great company. It guarded Baoshan but did not know how to commercialize it. When Apple CEO Jobs saw the system, he was shocked. Later, he tried his best to poach many technicians from Xerox and obtained the Windows system writing technology.
When Jobs learned the news, he was very angry, because his relationship with Bill Gates was quite good at that time, and he had a lot of business contacts. Jobs said to Gates, "Bill, you are so unkind. I believe you so much!"
So, Apple took Microsoft to court.
In the face of Jobs' plagiarism allegations, Bill Gates shrugged his shoulders and said to him, "We have a rich neighbor named Xerox. When I broke into their house to steal the TV, I found that you had stolen it."
After working on himself for a while in private, Lin Hong began to officially listen to the teacher Mike's class, but after listening for a while, he found that he could not understand it at all. What the other party is talking about now is already the lower part of the C language.
Therefore, Lin Hong wisely chose self-study, which is his consistent way of learning.
The textbook in hand is all in English. According to the literal meaning, the name of this book is C Programming.
Lin Hong already has the programming foundation of BASIC and assembly, and he knows it in his heart. This is another programming language.
He first looked at the preface, which introduced the origin of the language, the author of the invention and the development status.
After reading it, Lin Hong realized that the programming language he was about to learn was a very powerful language. It has the characteristics of both a high-level language and an assembly language.In fact, the C language is designed on the basis of the B language, which is the writing language of the first UNIX operating system. That is to say, C is a programming language that can be used to write operating systems. This is incomparable to BASIC in any case. Just seeing this, Lin Hong made up his mind to learn the language well.
When he saw the writing of the operating system, he couldn't help thinking of LUS.
"I don't know which programming language he uses to write the operating system..."
Put aside the distracting thoughts in his mind, Lin Hong began to concentrate on reading the textbooks in his hand.
This textbook is very systematic. It is more detailed than the introduction of BASIC in the red book he read before.
The author gave a "Hello_Wold!" at the front of this book. The example gave Lin Hong a general impression of it from the beginning. Then, starting from the initial basic grammatical variables, the narrative will be simple and wonderful. At the same time, there are many example codes for reference, and Lin Hong will soon be immersed in it.
While Lin Hong was reading alone, Arthur had been observing him behind him, and his eyes flashed thoughtfully.
It's fast. Mike finished the basic knowledge of this lesson, and then asked everyone to get on the computer and start to do it by themselves. If there is anything you don't understand, you can raise your hand and ask at any time.
Since Lin Hong is a new student, Mike is more concerned about him. Just now in class, I had observed that Lin Hong was doing his own thing. Of course, he did not have any opinion on this. After all, this is their reason. If the student does not listen to his lecture, the course he teaches is too boring to attract the attention of the students.
If students feel that the teacher's lecture is not helpful to them, they can choose not to listen. Even more serious people can also apply to the school for a change of teachers. If there are more students applying and the school also believes that this is necessary, Mike may really face the risk of being laid off.
"Hi, nice to meet you. I'm Mike. What's your name?" Mike walked to Lin Hong and saw that he was concentrating on reading. He couldn't help nodding slightly. Students who like to study are more popular with teachers everywhere.
Lin Hong looked away from the book. He turned his head and looked at the bald man and said, "I'm glad to see you, too. I'm STONE*Lin.
"STONE, this is your first time to come to class, right?"
Lin Hong nodded: "Yes"
"Where are you from? Does it look like an Asian? Day] Ben?"
"No, it's not." Lin Hong quickly shook his head, "I'm from China, from Beijing, and I'm an exchange student."
"Oh, right? You are an exchange student from Beijing!" Mike was very surprised. There are also some Chinese students here, but many of them are Chinese Americans, but there are very few students who really come from Beijing.
Seeing that Lin Hong didn't say anything more, he just looked at him with a puzzled face. Maybe he was worried that Lin Hong would misunderstand him. He quickly said, "I'm sorry, I'm just a little surprised. I don't mean anything else. I want to say, do you need any help?"
"Help?" Lin Hong hesitated for a moment and really asked a question: "Teacher, I want to ask, where is the compiler of C language?"
"Mike, just call me Mike." Mike corrected, and then he asked, "Have you ever been exposed to programming languages before?"
The reason why he asked this is that the question asked by Lin Hong is more critical. If you are a beginner, you have no idea about the compiler.
The English compilation is "compile", which means "collect, compile" and later translated into Chinese according to the situation and meaning, that is, "compilation" means "collect" and "translate".
The emergence of high-level languages is entirely to facilitate programmers, improve readability and reduce the difficulty of programming, but for computers, high-level languages are like a foreign language, directly "speak" to it, and it has no understanding what you are talking about.
So you need to use a "translation". The compiler plays the role of translating high-level languages into machine codes that computers can understand. It is this middleman who can understand both the "foreign language" of high-level language and the "indigenous language" of the computer.
Of course, there are actually two different types of translation. One is "simultaneous interpretation", that is, when you hear "foreign language", the translation comes out smoothly and speaks while listening. This type of language is called "explanatory language".
Another translation is to listen to you completely first, then translate all the contents into a translated manuscript, and finally throw it to the computer for him to execute. In this process, translation may also be based on the "indigenous" habit of computers. Organize the translation so that it is smoother and free from grammatical errors, so that the "indigenous" can better perform these tasks. Such a language is the real "compiled language".
In fact, the "translation" of BASIC language belongs to the former, while the "translation" of C language belongs to the latter, but at present, Lin Hong does not understand this truth and thinks that the translation process of these two languages is similar.
In the face of Mike's problem, Lin Hong nodded and said, "Yes. I have learned BASIC."
"Oh, it's very good! If so, you should also learn the C language well. Although they are two different languages, they are in programming ideas. Many things are connected. Mike said with a smile.
"Programming idea?" Lin Hong is very strange to this word.
Mike thought that Lin Hong didn't hear it clearly. After all, for foreign students, many of them have language barriers in this regard. Lin Hong is one of the easiest foreign students he has ever seen, so he immediately slowed down and repeated this word.
"What is the programming idea?" Lin Hong asked.
When Mike heard his question, he thought about it for a while, and then said in the way he thought was the most understandable: "This is a big topic. It covers a wide range. To put it simply, this is the way we think about problems. Programming ideas are the way of thinking that we use computer programming to solve practical problems.
Lin Hong nodded as if he didn't understand.
Then, after a few more words, Mike started the C compiler from the computer, and then gave him a general explanation of the basic operation of the compiler. For example, save, modify, compile and run programs, and these operations have corresponding shortcut keys. It can greatly improve the speed and efficiency of operation.
In addition, Lin Hong asked another question. He found that the Apple machine also had a small oval peripheral on the right side and connected to the chassis. Moreover, this thing was a little different from the one he received from his family. There were not two buttons on it, but only one button.
Mike smiled and explained it to him in detail, saying that this thing was called "mouse" APPLE-II was not equipped with this at the beginning, but later it became the standard. Moreover, the mouse of Apple and PC is different. Apple's mouse has only one button, while other computers have two.
At this time, another student was shouting Mike's name, and he left.
Although this image of Mike looks difficult for men to approach, it is very friendly and warm-hearted. Lin Hong can see that he gets along well with other students. They play American jokes with each other, as if they are equal friends.
Because Lin Hong has just arrived here, he can't help comparing these things with the domestic situation. Although he only stayed in S for a short time, he has basically understood the teaching situation in S. He found that there are great differences between China and the United States in many aspects.
Of course, he can't judge what is good and what is unscientific.
Lin Hong seemed to return to learning the BASIC language for the first time. He began to type in one character at a time according to the example code on the textbook, and then compile and run.
"Hello_world!" soon appeared on the monitor. The string.
The important first step has been taken. Looking at the results on the monitor, Lin Hong smiled and continued to read other content.
variables, data and operators, programming structures, loops, pointers, arrays...
Lin Hong found that there is a big difference between C language and BASIC. It has many functions that BASIC does not have, some of which are closer to assembly language and involve some operations of memory and underlying interfaces. Lin Hong was completely attracted by these contents and quickly absorbed the water in it like a sponge.
Just as he was fascinated, he suddenly heard a "beep" sound in his ear. Lin Hong was very familiar with the sound. He knew that this was the sound of the computer's built-in loudspeaker.
Lin Hong subconsciously looked up at the display, but was very shocked to find that he didn't know when a black box appeared in the display. In this black box, there was a line of green text, which shocked him!
"STONE,IF_YOU_LIKE_COMPUTER,I_CAN_TEACH_YOU. STONE, if you like computers, I can teach you)