In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-25 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
Editor to share with you what Java interview skills, I believe that most people do not know much about it, so share this article for your reference, I hope you will learn a lot after reading this article, let's go to know it!
1. Briefly introduces the robustness of Java programs.
A: the Java program automatically detects possible errors when compiling and running, and it is a strongly typed language, it is very strict for type checking, and its garbage collection mechanism effectively avoids memory leaks.
two。 Why?
A: because it does not support any process-oriented programming techniques, all of its programming techniques are implemented with classes.
Another answer: because it has eight simple data types that are not object-oriented, you can use it directly. Variables or methods declared in static are not object-oriented, because it does not belong to any object, and you can use it directly to call it without instantiating it (this method is still under debate).
3. Briefly describes how Java implements security.
Answer: first of all, Java removes the pointer, which avoids illegal memory operations, and all memory operations must be done through an instance of the object. And when we download code from the Internet for execution, its security system ensures that malicious programs do not casually access the resources of our local computer.
4. Why is Java explanatory?
A: because when we execute a Java file, the compiler translates the code into a bytecode file, which is an intermediate code, and then the Java interpreter executes it.
5. A brief introduction to Java's platform independence.
A: the Java program is executed on a virtual machine, and as long as the JAVA virtual machine is installed, it can be executed in the form of bytecode on any platform.
6. The polymorphism of Java is briefly introduced.
Answer: polymorphism means that different methods of the same name are stored in the program, and the system calls different methods to achieve different functions according to different situations. There are two ways to achieve polymorphism: override implementation and overload implementation.
7. Briefly introduce that Java is a strongly typed checking language.
Answer: Java is very strict in checking data types. When defining and using variables, you must first specify their types, and it only allows the upward promotion of data types, and does not allow additional values that will cause data loss (such as attaching decimals to shaping).
What's the difference between 8.int and Integer?
A: int is a simple data type (shaping) and Integer is a wrapper class for shaping.
9. Briefly introduce the difference between String and StringBuffer?
Answer: the String class represents an immutable string. The value cannot be changed after it has been created. StringBuffer is a variable character sequence with an initial capacity of 16 bytes, and its content and length can be changed by some methods.
10. This paper briefly introduces the garbage collection mechanism of Java.
Answer: method to configure system resources or perform related cleanup operations.
The above is all the contents of the article "what are the skills of Java interview". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.