After researching more than 500 PDF documents, I discovered the secret of Java programmers "millions of annual salary" (super detailed, recommended for collection)

Introduction

This article is a real face-to-face experience of a fan friend some time ago. It was Mogujie. It happened that the interviewer was Ao Bing. Now Ao Bing has gone to Tencent to find a job.

Background introduction:

Work experience: 5 years of Java development

Education background: Chongqing University of Posts and Telecommunications (Information Security Major)

Work experience: The main business is to make mobile payment wallets in Cambodia (aggregate payment project, so that local Chinese in Cambodia can use WeChat and Alipay to pay)

Note: The following content is all real face-to-face sharing. You can read it carefully to see if you can answer these interview questions to the interviewer's satisfaction. At the same time, I will share some interview tips for everyone, mainly to tell you how to prepare Resume, how to prepare for the interview, the real interview questions of 2020 Dachang (including answers), and which learning materials are worth looking at.

Not much to say, let’s follow this fan friend’s interview experience to take a look at his interview journey. In addition, the answers to the interview questions and review materials involved in the following are all shared in full PDF version, and after three consecutive years, they will write to me "Interview" is enough~

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

 

Interviewer: introduce yourself

Programmer: Hello, I graduated from XXX and have been working for 5 years. The most recent job is mainly responsible for XXX (see the background introduction above)

Interviewer: Seeing that you have written proficiency in the advanced features of the Java language, let’s briefly introduce the injection process of Bean SpringBean.

Programmer: Bean injection process...First, it and the object from the configuration file (annotation)... Um, I am still not familiar with this aspect

Interviewer: It’s okay, it’s okay...Let’s go on

Programmer: smile awkwardly

Interviewer: I think you wrote that you know some advanced features. Can you give me a brief introduction to the new features of Java 8, or what are the new features that you are good at?

Programmer: Java 8 is mainly a lambda expression in terms of syntax. It can be used for functional programming. The functional interface means that this interface has only one method.....

Interviewer: Is there anything else?

Programmer: There are also some stream operations, such as: Stream API, which can simplify programming semantics and make it clearer. For example, when doing a filter function, you can bind data to filter out data that does not meet the requirements. Just write it in the previous words. A for loop does not seem to be so easy to understand... and then some optimizations are made to the data structure, like ConcurrentHashMap, its underlying implementation is changed to a red-black tree...

Interviewer: What you just said are some optimizations, I asked about some of its new advanced features

Programmer: Smile again...

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

Interviewer: You just mentioned its streaming processing. Compared with foreach or basic for loop, is it optimized for efficiency, or is it slower? Have you ever been to find out?

Programmer: Uh... no

Interviewer: I think you said you have some understanding of concurrent programming. Can you tell me about the underlying implementation principles of Synchronized and Lock?

Programmer: Ah...Synchronized is a semantic level support. It is in an object header. It has a Mark Word mark to record its lock. Lock shows that the lock uses its underlying AQS. A first-in-first-out queue of a doubly linked list. Only the thread currently holding the lock is a counterpart. After it is released, it will use a spin operation to make the next thread the head of the queue.

Interviewer: What are the levels of the two? Is it the jdk level or the JVM level, or?

Programmer: Synchronized is at the JVM level, and Lock is at the jdk level

Interviewer: You mentioned Synchronized just now. Have you ever understood how its lock method, lock object, and lock code block are implemented?

Programmer: Um... Nothing

Interviewer: Do you know the synchronization lock upgrade process?

Programmer: No...

Interviewer: I just mentioned Lock. Can you give me a brief introduction to CAS?

Programmer: CAS is to compare and exchange

Interviewer: Yeah, it’s enough to mention this. Do you have any practical applications in the actual development process? A process applied to optimistic locking

Programmer: Yes, for example, when I update the database, if a database uses optimistic locking, I also use a spin operation to update it until it succeeds.

Interviewer: Is the efficiency of spin very low? If you can't get this lock all the time, it may cause some threads to be blocked, or other will affect a lot of efficiency in high concurrency scenarios. Is this problem considered?

Programmer: Also considered.....If the concurrency is high, it is really not suitable to use spin, this time is more suitable to use pessimistic lock

Interviewer: Then talk to me about the thread pool

Programmer: The thread pool is... I will talk about its workflow first, and then it will be submitted first. It will enter the core eat first. If the thread book is larger than coreSize, it will enter a blocking queue. When it is full, it will create some new threads and enter the largest pool; when the number of threads, even maxSize exceeds, it will execute a rejection strategy. There are four rejection strategies that JDK comes with: one is directly discard; One is to throw an exception; the other is to be executed by the caller's thread; the other is to discard the thread with the longest waiting time in the blocking queue

Interviewer: I think your resume also mentions proficiency in JVM tuning. Can I ask you about some of the basic steps of tuning it?

Programmer: Ah...a bite of blood, the basic steps of tuning... For example, I start from... um... I start from OOM... If an OOM exception occurs in production, The first is to judge whether it occurs in the heap or in the metaspace, and... it has another type that is too low in GC efficiency.....

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

 

Note: Due to the excessive content, to avoid affecting the reading experience, I will not code the following interviews, and replace them with screenshots!

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

 

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

 

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

 

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

Interviewer: I think you basically leave after staying for a year. Can you tell me the reason for your leaving?

Programmer: .........

Interviewer: What is your career plan?

Programmer: Go to the Internet finance industry

Interviewer: What do you want to ask me?

Programmer: I asked something I didn’t know much before

Interview summary: It can be seen from this interviewer that the interviewer did not ask deeply, otherwise it is estimated that 80% of the content will not be answered. Basically, they are basically basic things. The bottom content is not asked much, so I wrote a Dubbo On the resume, the interviewer did not ask him Spring Cloud, Hystrix container, etc., even bus can ask a lot of things, once asked, it is really embarrassing, asking about doubting life.

How to prepare for an interview

First of all, like this friend, you can vote for some small company resumes, go to an interview for literacy, see what you don’t know, what knowledge you lack, and then go home to do an interview review.

Optimize your resume, don’t write a Dubbo, and then you won’t be able to answer if the interviewer asks a little deeper. Pay attention to the following three points on your resume:

(1) Pay attention to the distinction: understand, be familiar, proficient, don't write randomly, many questions of the interviewer are based on the description of the resume;

(2) The professional knowledge and project experience are not very refined, especially the project experience must write what you are familiar with and have content to say, don't think that the more you write, the better;

(3) To be familiar with the content of your resume and master it accurately, it is best to read more of your resume.

Secondly, you can also prepare in the early stage, brush more interview questions, watch more learning materials or video tutorials, etc. Here I will also share some of the learning materials I have collected and the real interview questions to share with you, Sanlian Then, add the following VX to receive directly~

 

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

Java core content finishing

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

Real interview questions

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

Suggest

You can summarize and extend the knowledge of Java basics, JVM, concurrent programming, MySQL, Redis, Spring, Spring cloud, etc., and then perform operations, otherwise you will not be able to learn just remembering, here I also provide some brain maps to share give everyone:

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

 

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

 

Interviewer: I asked for 25K, so I used 2 success power to ask you to doubt life (Java)

 

At last

No matter which company it is, it attaches great importance to the basics. Large companies pay more attention to the depth and breadth of technology. The interview is a two-way selection process. Don't go to the interview with a fearful mind, which is not conducive to your performance. At the same time, you should not only pay attention to salary, but also whether you really like this company and whether you can really get exercise.

Regarding the above interview technical points, I also do some information sharing here, hoping to better help you. After three consecutive times, you can privately message "Interview" or scan the bottom~

 

I hope everyone can get a satisfactory offer in Jinjiu Yinshi!

Guess you like

Origin blog.csdn.net/sinat_37903468/article/details/109075819