Java Programmer Interview Questions

26,868 java programmer interview questions shared by candidates

aptitude are from number series and mixtures, C,C++ are from pointers Java from Threads, In programming round they asked, Program to print matrix in spiral form, Program to reverse vowels alone in a given string program to push all zeros to right side in an array and order should be maintained program to print name in a list like below if list contains 10-20 strings and if input is like c*i o/p should print all string in a list contains words starting with 'c' and ending with 'i' eg: list = [chennai, covai, madurai, delhi, dubai, mumbai] then if i/p = c*i o/p-->> chennai, covai if i/p = d*i o/p --->> dubai, delhi
avatar

Java Developer

Interviewed at Zoho

4.2
Feb 23, 2017

aptitude are from number series and mixtures, C,C++ are from pointers Java from Threads, In programming round they asked, Program to print matrix in spiral form, Program to reverse vowels alone in a given string program to push all zeros to right side in an array and order should be maintained program to print name in a list like below if list contains 10-20 strings and if input is like c*i o/p should print all string in a list contains words starting with 'c' and ending with 'i' eg: list = [chennai, covai, madurai, delhi, dubai, mumbai] then if i/p = c*i o/p-->> chennai, covai if i/p = d*i o/p --->> dubai, delhi

Implement a method 'find' that will find the starting index (zero based) where the second list occurs as a sub-list in the first list. It should return -1 if the sub-list cannot be found. Arguments are always given, not empty. Sample Input 1 list1 = (1, 2, 3) list2 = (2, 3) Sample Output 1 1 Explanation As second list (2, 3) is sub-list in first list (1, 2, 3) at index 1 Sample Input 2 list1 = (1, 2, 3) list2 = (3, 2) Sample Output 2 -1
avatar

Senior Java Developer

Interviewed at Atlassian

3.1
Apr 13, 2016

Implement a method 'find' that will find the starting index (zero based) where the second list occurs as a sub-list in the first list. It should return -1 if the sub-list cannot be found. Arguments are always given, not empty. Sample Input 1 list1 = (1, 2, 3) list2 = (2, 3) Sample Output 1 1 Explanation As second list (2, 3) is sub-list in first list (1, 2, 3) at index 1 Sample Input 2 list1 = (1, 2, 3) list2 = (3, 2) Sample Output 2 -1

String,String buffer,String builder difference. Can u write your own immutable class n how? hashmap implementation and hashcode(),equals() method he asked me to write 2 logical testing programs with reduced complexity( 0,1,1,2,4,5,3,3,1,0,1 traverse once only n get the duplicate number's along with the count). printing pascal triangle duplicate letter from a string with less complexity reversing words of string individually(this is a tree---o/p: siht si a eert)
avatar

JAVA DEVELOPER

Interviewed at Oracle

3.5
May 25, 2015

String,String buffer,String builder difference. Can u write your own immutable class n how? hashmap implementation and hashcode(),equals() method he asked me to write 2 logical testing programs with reduced complexity( 0,1,1,2,4,5,3,3,1,0,1 traverse once only n get the duplicate number's along with the count). printing pascal triangle duplicate letter from a string with less complexity reversing words of string individually(this is a tree---o/p: siht si a eert)

Viewing 51 - 60 interview questions

Glassdoor has 26,868 interview questions and reports from Java programmer interviews. Prepare for your interview. Get hired. Love your job.