Thursday, July 10, 2014

Top 50 Java Thread Interview Questions Answers for Freshers, Experienced Programmers

You go to any Java interview, senior or junior, experience or freshers, you are bound to see couple of questions from thread, concurrency and multi-threading. In fact this built-in concurrency support is one of the strongest point of Java programming language and helped it to gain popularity among enterprise world and programmers equally. Most of lucrative Java developer position demands excellent core Java multi-threading skills and experience on developing, debugging and tuning high performance low latency concurrent Java applications. This is the reason, it is one of the most sought after skill on interviews. In a typical Java interview, Interviewer slowly starts from basic concepts of Thread by asking questions like, why you need threads, how to create threads, which one is better way to create threads e.g. by extending thread class or implementing Runnable and then slowly goes into Concurrency issues, challenges faced during development of concurrent Java applications, Java memory model, higher order concurrency utilities introduced in JDK 1.5, principles and design patterns of concurrent Java applications, classical multi-threading problems e.g. producer consumer, dining philosopher, reader writer or simply bounded buffer problems. Since its not enough just to know basics of threading, you must know how to deal with concurrency problems e.g. deadlock, race conditions, memory inconsistency and various thread safety related issues. These skills are thoroughly get tested by presenting various multi-threading and concurrency problems. Many Java developers are used to only look and read interview questions before going for interview, which is not bad but you should not be too far away. Also collecting questions and going through same exercise is too much time consuming, that's why I have created this list of top 50 Java multi-threading and concurrency related questions, collected from various interviews. I am only going to add new and recent interview questions as and when I am going to discover them. By the way, I have not provided answers of this questions here, Why? because I expect most of Java developer to know the answers of this question and if not, also answers are widely available by using Google. If you don't find answer of any particular question, you can always ask me in comments section. You can even find answers of few questions on the link provided or my earlier post Top 12 Java Thread Questions with Answers.

Read  more here

Leave a Reply

All Tech News IN © 2011 & Main Blogger .