[Reproduced] Java interview questions

xiaoxiao2021-03-06  21

First, talk about the difference between Final, Finally, Finalize. It is most often asked. Second, anonymous inner class (anonymous internal class) can be extends other classes, can IMPLEMENTS INTERFACE (interface)? Third, Static Nested Class and Inner Class are different, the more better, The interview question is very general). The difference between fourth, & and &&. This is very small. Fifth, the difference between HashMap and HashTable. I often ask. Sixth, the difference between Collection and Collectes. Don't say one is a single one is a plural. Seventh, when do you use Assert. API-level technicians may ask this. Eighth, what is GC? Why have a GC? Foundation. Ninth, string s = new string ("xyz"); created a few String Object? Tenth, Math.Round (11.5) is equal to how much? Math.Round (-11.5) is equal? ​​Eleventh, Short S1 = 1; S1 = S1 1; What is wrong? SHORT S1 = 1; S1 = 1; What is wrong? The interview question is very variable, and it is necessary to prepare for abuse. 12. What is the difference between SLEEP () and WAIT ()? Making the favorite of threads. Thirteenth, there is no goto? It's a very thirteen problem. If you ask this question, I advise you still in this company. Fourteenth, there is a length () method in the array? String has a length () method? The difference between the fifteenth, overload and override. Can OVERLOADED methods change the type of return value? Often asked. Tenth, the elements in the set cannot be repeated, then what method is used to distinguish whether it is repeated? Is it == or equals ()? What is the difference? Seventest, give me one of you most often Runtime Exception. If you can't answer this, the interview will think that you don't have practical programming experience. Eighteenth, what is the difference between ERROR and EXCEPTION? Are the nineteenth, List, SET, MAP inherit from a Collection interface? Ten, what is the difference between Abstract Class and Interface? Second Eleventh, whether the method of Abstract can be Static, whether it can be Native at the same time, is it possible to be SYNCHRONIZED? 22, whether the interface can inherit the interface? Does the abstract class can implement (IMPLEMENTS) interface? Whether the abstract class is Can I inherit the physical class (Concrete Class)? On the second thirteenth, start a thread is Run () or start ()? 24. Is the constructor can be override? Second fifteenth, can you inherit the String class? 26. After a thread enters an SYNCHRONIZED method of an object, does other threads can enter this object? Second 17, there is a return statement in TRY {}, then follow this TRY The code in finally {} will not be executed, when is executed, before returbium or after? Twon 11, program: 2 multiplied 8 equal to a few? There is a C background Programmers especially like to ask this question.

转载请注明原文地址:https://www.9cbs.com/read-47445.html

New Post(0)