Java interview Summary, very worth a look

Source: Internet
Author: User
First stage: three years

I think three years is the first hurdle for programmers, and this phase will eliminate a bunch of people who are not fit to write code. At this stage, we go out of campus, into society, become a programmer, formally from the content of books to real enterprise-level development. We know how to work together, how to use Project management tools, how project versions are controlled, how we write code to test how to run online, and so on, have accumulated some development experience, but also have a certain depth of understanding of the code, is a relatively pure coder stage.


Phase two: five years


Five years is the second hurdle for separating programmers. Some people in the three years, in addition to complete the work, in free time basically will not study other things, these people will always be a coder, older some are bound to be younger people to replace; some people in the three years, in addition to writing code, but also keen to study various technical implementation details, read n Many good books, write some blog, Sharing technology on GitHub, these people in five years will certainly have the ability to independently and clear their future direction, from a coder gradually to the system analyst or architect, become the project team indispensable figure.


Phase III: Ten years


Ten years is another hurdle, a career change or a programmer on this node. If in the past few years to cling to the idea of a career and work for it, then in 10 years of this node, some people will grow up to be a deep understanding of the industry, a deep understanding of technology, can start from scratch on a product analysis of the programmer, such people in the company are basically the CTO, technical experts, chief The most critical positions for architects and so on, this is absolutely a glorious thing for you, of course, the boss in the financial will not be mistreated you.


In the first part, I think that with the growth of your work and the depth of your understanding of life, you should keep thinking about three questions:

1, I really fit to be a programmer.

2, I should not be a lifelong programmer for career.

3, I to programming in the end is what kind of attitude, is enough for good or continuous research.

Finally, define your career plan, be responsible for your own planning and work for it.



About Project Experience


On the internet often see some other friends have to put forward project experience, according to my interview feeling, the main interview to see some: Project experience + basic technology + personal potential (that is, the value is not worth training).


About project experience, I think the founder of concurrent programming network to take off the teacher said a passage is very good: when introducing the product, the interviewer examines the candidate's ability to communicate and think, and most of the time we do a function or a module of the product, but even so, do we have the whole system structure or product to understand, And can introduce clear, why do this system. What the value of this system is. What is the function of this system? What are the pros and cons? If you were to redesign the system, how would you design it?


I think that's enough to generalize. Maybe you're only working for a year, and maybe you're doing the trivial modules of the project, and of course these are your weaknesses and cannot be changed, but how to make up for this disadvantage.


From the side of the teacher's words I sum up a few:

1, clearly what your project is doing, what functions.

2, clear the overall structure of your project, in the interview can be clearly drawn to the interviewer to see and clearly indicate where to call from where, use what way to call.

3, clear your module in the entire project position and role.

4, clear your module to use what technology, better some can understand the whole project to what technology.


In situations where you can't change your working life and your own less compelling project experience (which must be a deduction), you can make up for it in some way and improve the interviewer's affection for you.



About professional skills


Writing a project and then writing about the skills that a Java programmer with 3 years of experience should have is probably something that Java programmers are more concerned about. Here's what I'm going to say: The list below is not something that will happen-but the more you master, the higher the amount of evaluation and salary you will get.



1 Basic Grammar



This includes static, final, transient and other keywords, the principle of the Foreach loop and so on. Today, I asked you what the static keyword does, if you answer the static modifier variable, cosmetic method I will think you qualified, answer the static block, I will think you are good, answer the static internal class I will think you are very good, answer the static guide bag I will be very satisfied with you, because can see you are very keen on research technology.

In the deepest time, I remember that the interviewer asked me directly about the underlying implementation of my volatile keyword (by the way, interviewing and being interviewed are relative, and the interviewer also makes the interviewer feel that the interviewer is also a person who loves to study technology, adding to the interviewer's affection for the company, I finally chose to ask the question of the company), do not feel that this is too picky-the simpler the problem is more to see a person's level, others to your technical considerations are most of the depth of priority, breadth second to the standard, remember.


2 Collection



Very important, but also must ask the content. Basically is list, Map, Set, ask is the implementation of the underlying implementation of the principle of classes, implementation of the advantages and disadvantages of the class.

Set to master the principles of ArrayList, LinkedList, Hashtable, HashMap, Concurrenthashmap, HashSet, can answer fluently, Of course, it would be better to master the Copyonwrite container and queue. In addition to say one more, concurrenthashmap questions in the interview asked a lot, probably because this class can derive a lot of questions about Concurrenthashmap, I give friends to provide three points to answer or research direction:

(1) Concurrenthashmap of the lock-segment technology.

(2) Whether the Concurrenthashmap should be added to the lock, why.

(3) The Concurrenthashmap iterator is a strongly consistent iterator or a weakly consistent iterator.


3 design mode



Originally thought quite important piece of content, the results only in Alibaba Business Department interview when asked once, then asked is the adorner mode.


Of course, we can not so utilitarian, in order to study for the interview, design patterns in the work is still very important and very useful, 23 kinds of design patterns in the focus of research on a dozen of the most commonly used, the interview on the design pattern of the answer is mainly three directions:

(1) What design patterns are used in your project and how to use them.

(2) know the advantages and disadvantages of the common design pattern.

(3) Can draw the common design pattern UML diagram.


more than 4 threads



This is also a must-ask piece. Because three years of work experience, so basically will not ask you how to implement multithreading, will ask in-depth some such as thread and runnable difference and contact, multiple start a thread, what the state of the thread. Of course, this is only the most basic, unexpectedly, a few interviews are almost all at the same time asked a question, the method is different.


Summed up is such a meaning:

If there are Thread1, Thread2, ThreaD3, Thread4 Four thread statistics of C, D, E, f four disk size, all the threads are counted to the THREAD5 thread to do the summary, how should be achieved.


Smart netizens have an answer to this question. It's not hard to java.util.concurrent that there are ready-made classes to use.


In addition, the thread pool is also a more frequently asked piece, the common thread pool has several. What are the differences and connections between these thread pools? The principle of how the thread pool is implemented. Practical, it will give you some specific scenes to let you answer this scenario to use what kind of thread pool is more appropriate.


Finally, although this interview does not ask much, but multithreading synchronization, lock this piece is also the focus. Synchronized and Reentrantlock difference, synchronized lock common method and lock static method, the principle of deadlock and the method of troubleshooting and so on.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.