Interview series (11): 85 questions for bat interview

Time:2019-12-2

JVM topic

Interview series (11): 85 questions for bat interview

(see the home page for interview questions + Answers)

  1. Java class loading process?
  2. Describe how the JVM loads class files?
  3. JAVA memory allocation.
  4. What is a GC? Why do we need a GC?
  5. A brief introduction to Java garbage collection mechanism.
  6. How to judge whether an object is alive or not? (or the determination method of GC object)
  7. Advantages and principles of garbage collection. Two recovery mechanisms are considered.
  8. What is the basic principle of garbage collector? Can the garbage collector reclaim memory right away? What’s the way to actively notify the virtual machine for garbage collection?
  9. Is there a memory leak in Java? Please describe it briefly.
  10. Deep copy and light copy.
  11. What do system. GC () and runtime. GC () do?
  12. When is the finalize () method called? What is the purpose of a destructor?
  13. If a reference to an object is set to null, will the garbage collector immediately release the memory occupied by the object?
  14. What is distributed garbage collection (DGC)? How does it work?
  15. What is the difference between a serial collector and a throughput collector?
  16. When can objects be garbage collected in Java?
  17. Briefly describe JAVA memory allocation and recovery policy rate, minor GC and major GC.
  18. Will garbage collection occur in the permanent generation of the JVM?
  19. What are the methods of garbage collection in Java?
  20. The mechanism of parent delegation model of classloader?

Database topics

Interview series (11): 85 questions for bat interview

  1. Please briefly describe the four transaction isolation level names supported by InnoDB in MySQL and the differences between them?
  2. What is the usage of enum in MySQL?
  3. What is the difference between char and varchar?
  4. What can be the string type of a column?
  5. What storage engine is used in MySQL?
  6. What does timestamp do with the update current? Timestamp data type?
  7. What’s the difference between a primary key and a candidate key?
  8. What are the MySQL database server performance analysis method commands?
  9. What’s the difference between like and regexp operations?
  10. What’s the difference between blob and text?
  11. Three paradigms of database?
  12. How many triggers are allowed in MySQL tables?
  13. What are general SQL functions?
  14. What are the locks in MySQL?
  15. MySQL data optimization.
  16. Keywords for MySQL.
  17. Storage engine.
  18. Database backup.
  19. The difference between truncate delete drop.
  20. What is redis? Two sentences to summarize.
  21. Redis (pipeline, hash).
  22. Redis implementation principle or mechanism.
  23. Redis has two types of partitions.
  24. What is mongodb.
  25. Mongodb features.
  26. Mongodb features.
  27. Applicable scenarios of mongodb.
  28. Comparison of redis, Memcache and mongodb.
  29. What’s the use of redis? Only when we understand its characteristics, can we use it for us.

Collection framework theme

Interview series (11): 85 questions for bat interview

  1. The difference between ArrayList and vector.
  2. Talk about the storage performance and features of ArrayList, vector and LinkedList.
  3. What is the difference between fail fast and fail safe?
  4. Data structure of HashMap.
  5. How does HashMap work?
  6. When will HashMap be expanded?
  7. What are the characteristics of list, map and set interfaces when accessing elements?
  8. The elements in the set can’t be repeated. What’s the way to distinguish whether they are repeated? Is it = = or equals ()? What’s the difference between them?
  9. Two objects have the same value (x.equals (y) = = true), but they can have different hash codes, right?
  10. What’s the difference between heap and stack.
  11. What are the basic interfaces of the Java collection class framework?
  12. What’s the difference between HashSet and TreeSet?
  13. What is the underlying implementation of HashSet?
  14. How does LinkedHashMap work?
  15. Why does the collection class not implement the Cloneable and serializable interfaces?
  16. What is iterator?
  17. What is the difference between iterator and listiterator?
  18. What’s the difference between array and ArrayList? When should I use array instead of ArrayList?
  19. What are the best practices of the Java collection class framework?
  20. The elements in the set cannot be repeated, so what method is used to distinguish whether they are repeated or not? Is = = or equals()? What’s the difference between them?
  21. What is the interface between comparable and comparator? List the differences.
  22. The difference between collection and collections.

Multithreading / high concurrency topics

Interview series (11): 85 questions for bat interview

  1. Why are stop() and suspend() methods not recommended?
  2. What’s the difference between sleep() and wait()?
  3. What are the similarities and differences between synchronous and asynchronous, and under what circumstances are they used separately?
  4. When a thread enters a synchronized method of an object, can other threads enter other methods of the object?
  5. Briefly describe the similarities and differences between synchronized and Java. Util. Concurrent. Locks. Lock?
  6. A general explanation of several available states of threads.
  7. What is ThreadLocal?
  8. Run () is different from start ().
  9. Please say what you know about thread synchronization.
  10. Thread scheduling and thread control.
  11. What is thread starvation and what is live lock?
  12. What is a busy cycle in multithreading?
  13. What is the volatile variable? What’s the difference between a volatile variable and an atomic variable?
  14. What guarantees do volatile type variables provide? Can a non atomic operation be turned into an atomic operation?

Recommended Today

What is blockchain? A story tells you how bitcoin works

A story tells you how bitcoin worksRecommend:Artificial intelligence: the age of artificial intelligence in the romantic capital of FranceFlowers are not flowers, things are not things, AI is not things in the pool (chapter of artificial intelligence)To our youth, a salute Pictures may be lost. It is recommended to read the original I spent the […]