My son said, "I want to study programming," so I gave him an on-boro PC that was lying around at home, saying, "What should I do?" And "Introduction to Java." (Terrible) That's not enough, so I thought I'd read about "Introduction to Java" again and summarize what I was interested in and what I shouldn't do.
[Introduction to Java](https://books.rakuten.co.jp/rb/14782914/ ()
――The target is my son ――It's just an individual impression ――We have the first edition of the first edition
There was a time when it was said that the processing speed was slower than the language that generates and executes a machine language program that the CPU can understand, such as C language.
It has improved to a speed comparable to C language.
People, people, people, people > Sudden C <  ̄Y^Y^Y^Y^Y ̄
I'm sorry, I wanted to try it once.
Joking aside, I was a little wondering what percentage of beginners and beginners who picked up this book were experiencing the C language. I'm not afraid that this kind of thing no longer acts as a counter to the discourse that "Java is slow", which is still being said by some.
Is it Windows only? This kind of thing is mostly Windows only, Mac only, or both. People who use other than that are at their own risk, aren't they? It was a complaint of using Xubuntu.
The PC I gave my son had Xubuntu 08.04 installed, and JDK6 (!) And Eclipse (about 3.3?) Were already installed, so I think this area is through.
Arithmetic and relational operators can be understood with knowledge of arithmetic, so can logical operations and bit operations be written lightly and make sense? No, is it natural that a person who wants to learn a programming language understands the basics of computer science? Then where and how should I learn it? Toka Toka. When I read the introductory book again from the perspective of having beginners read it, I suddenly start to notice what I had passed by without worrying about anything. In that sense, it's awkward for my son, who wants to study programming, to suddenly hand over "Introduction to Java" and read it.
Therefore, the evaluation that "'○○○○' is recommended for beginners" may be seen from above, so I feel that you should not be blind. In the sense that what you take for granted may not be for others.
Many operators are used to calculate numbers and booleans, but the binary operator "+" and the assignment operator "+ =" can be used to combine strings.
I think it's worth mentioning that the String type is specifically specified in JLS. (Chapter 7 mentioned the String type in detail, but it didn't seem like that either.) I sometimes see the String type being treated specially (not just because of that) and the lack of understanding of it causing unnecessary confusion.
No, aside from the story that I haven't written while recently, in the explanation of break
It is convenient to describe in this form, especially when the conditions for terminating the loop are complicated or when there are multiple conditions.
There is, but if you are not careful, you can see the future of becoming a spaghetti code. Well, how to solve it may be a little further.
Does the student have MAX_SCORE
?
No, it's difficult to express the essential things with a simple sample code, isn't it? I also have the experience of being a lecturer at an in-house study session on object-oriented programming and died in a big explosion, so I understand it painfully. I remember now and my chest hurts.
Does the main method come out at this timing? I wonder if it's better earlier. I thought, but then it's surprisingly difficult to think about where to put it. At the time of Hello World, I think it's possible to say "everything starts from main" for the time being, but I think that chapter is probably going to be done without explaining anything. ..
In reality, I don't think there are quite a few people who write Java programs at work who have never written the main method ... That's horrible.
Therefore, it is no longer necessary to add "_" after the variable name.
I fully agree with that claim, but was this a notable major culture? Personally, I've occasionally seen local variables (methods) prefixed to "before" (often not limited to Java), but you may not have seen a trailing underscore.
Primitive types are basic data types consisting of boolean types, numeric types, and character types.
No, I think there are only boolean type and numeric type. char is an "integer" that stands for UTF-16, isn't it? cf. https://docs.oracle.com/javase/specs/jls/se8/html/jls-4.html#jls-4.2
For convenience, I think it is possible to say "character type".
The String type is used in the new example, and I thought that I didn't have to use the String type depending on what happened there, but after that
You can use the new keyword to instantiate a class, but for the String class you can use string literals to instantiate more concisely.
Did you want to connect to the explanation of this string literal?
In this chapter, we will talk about Java arrays and collections that you just know about.
No, I don't really have anything to do with it, but I was struck by the expression, "I just knew it." Also, when I say that, I feel that it is not limited to arrays and collections.
Note that the [] used to declare an array can be attached to a type or a variable. That is, you can write either an int [] array or an int array []. However, the former int [] array is recommended so that you can clearly see that it is an "int array".
It is written in JSL that this is a little more in-depth. cf. https://docs.oracle.com/javase/specs/jls/se8/html/jls-10.html#jls-10.2
Variables are attached because of their affinity with C and C ++, and although you can write something like int [] array [], it seems that it is not recommended.
Due to time constraints, we will stop here.
Of course, there are a lot of things that I like in "Introduction to Java", so I thought it was necessary to make an effort to spread those things together. Let's do it with next year's Advent Calendar.
Recommended Posts