Posts

Showing posts with the label Interview

Today Walkin 26-Sept-2024

  Today Walkin 26-Sept-2024 Update coming soon.... Bangalore: Mumbai: Chennai: Hyberabad: Pune: Delhi(New Delhi): NCR: Goregaon: Kolkata: Bhubaneswar:

Today Walkin 25-Sept-2024

Today Walkin 25-Sept-2024 Update coming soon.... Bangalore: Mumbai: Chennai: Hyberabad: Pune: Delhi(New Delhi): NCR: Goregaon: Kolkata: Bhubaneswar:

List of common Google interview questions

 Here's a list of common Google interview questions, categorized by type: Coding/Algorithm Questions: Reverse a Linked List - Given a linked list, reverse it. Find the Longest Substring Without Repeating Characters - In a string, find the longest substring that does not repeat any characters. Merge Intervals - Given a collection of intervals, merge overlapping intervals. Implement a Trie (Prefix Tree) - Build a Trie data structure from scratch. Kth Largest Element in an Array - Find the Kth largest element in an unsorted array. Detect a Cycle in a Linked List - Given a linked list, determine if it has a cycle. Find All Anagrams in a String - Given a string and a non-empty pattern, find all substrings in the string that are anagrams of the pattern. Binary Tree Maximum Path Sum - Given a binary tree, find the maximum path sum. Rotting Oranges - Given a grid of oranges, determine how many minutes it takes for all oranges to rot, or return -1 if it is impossible. Word Ladder ...

Java interview programming question set-3

1) Fibonacci in Java: The input will be number n and the output should be sum for 0 to n. for example for n =4 the result should be 0+1+2+3+4 = 10 public class FibonacciNumber { public static int fibonacci(int n) {    if (n < 2) {     return n;    }    else {     return fibonacci(n-1)+fib(n-2);    }   } } view rawFibbonacci.java hosted with ❤ by GitHub 2) String Reverse The input String "abcde" should return "edcba". public reverse(String word) { char[] chs = word.toCharArray(); int i=0, j=chs.length-1; while (i < j) {  // swap chs[i] and chs[j]   char t = chs[i];   chs[i] = chs[j];   chs[j] = t;   i++; j--;  } } //Another way using java utility. import org.apache.commons.lang.StringUtils; String reverseWords(String sentence) {   return StringUtils.reverseDelimited(StringUtils.reverse(sentence), ' '); } view rawreverseString.java hosted with ❤ by GitHub 3) Reversing a linked list in...

Java interview question set-2

Image
1) Explain java class loading hierarchy? What will the sequence of class loading if we have classpath, ear file and war file? In this case first classpath library will be loaded first and then it will load application ear file library and after this default class loader will load class from web-inf\lib directory. Below is common class loading hierarchy. 2) Puzzle: if you have 5 kg gold bar and you have employee and his salary is 1 kg gold per day. We have to pay every day 1 kg to the employee how many cut we will do in gold bar to give him salary every day? answer : 2 cut and we will have 1 , 2 and 3 kgs bar and it is sufficient to give him every day 1 kg gold salary. 3) Why we need Wrapper class? 4) Is this class immutable? public void method1(StringBufer sb){ } No, As in java object reference is passed as value to method parameters, in above case StringBuilder reference is passed to the class which can change latter and it will modify the StringBuilder instance in class. 5) Differenc...

java interview question set-1

1) Tell me about career profile and describe your one of the main project?    then deep drive into the current project. Why u are using these technology like JMS, Concurrency, Spring in your application?  What feathers of java 1.6 you are using in your current application?  How you r managing concurrency in application?   How the exceptions are handled in your application? 2) Java collections - When to use ArrayList and Linked list? If we require random access in collection and We have more read compare to updates we should go for Arraylist. Linked list is good for more updates and removals from collection. Java Collection 3) Application wants to load static data with limited memory foot print and it should be refreshed after regular interval. Implement LRU Cache ? LRU Cache is related to removal of cache which is not used for maximum time. LRU Cache Implementation 4) What is soft reference, weak reference, phantom reference? A weak reference, simply put, i...

Database Interview Questions for Java Developers

Describe Oracle database's physical and logical structure ?   Physical : Data files, Redo Log files, Control file.    Logical : Tables, Views, Tablespaces, etc. Can a view be updated/inserted/deleted? If Yes - under what conditions ?   A View can be updated/deleted/inserted if it has only one base table if the view is based on columns from one or more tables then insert, update and delete is not possible. What is explain plan and how is it used ?  The EXPLAIN PLAN command is a tool to tune SQL statements. To use it you must have an explain_table generated in the user you are running the explain plan for. This is created using the utlxplan.sql script. Once the explain plan table exists you run the explain plan command giving as its argument the SQL statement to be explained. The explain_plan table is then queried to see the execution plan of the statement. Explain plans can also be run using tkprof. What is a mutating table error and how can you get around i...

Big data interview questions

Big Data Interview Questions JAVA related 1-1 ) What is the difference between List and Set ? The problem of getting old is still a commonplace here: List features: elements are placed in order, elements can be repeated, Set features: elements are not placed in order, elements cannot be repeated . 1-2 ) Three paradigms of databases? Atomicity, consistency, uniqueness 1-3 ) Java's io illustration class 1-4 ) Difference between object and reference object Object is a good object is not initialized, the referenced object even if the object has been initialized, the initialization can make your own direct new can also be directly to other assignments, then back new or back other assignment we call a reference to the object, The biggest difference is 1-5 ) Talk about your understanding of reflection mechanism and its use? There are three ways of obtaining the reflection, namely: the forName  / getClass / directly class manner using reflection may obtain an instance of t...