Interview questions

Software Developer interview questions – page 3

945 questions. Tap “Show answer” to check yourself.

  1. Write algo for reversing a linked list

  2. find out the subset of an array of continuous positive numbers from a larger array whose sum of of the elements is larger in comparision to other subset. eg: {1,2 5 -7, 2 5} .The two subarrays are {1,2,5} {2,5} and the ans is {1,2, 5} as its sum is larger than{2,5}

  3. You are given two strings s1 and s2.Now, find the smallest substring in s1 containing all characters of s2

  4. What if any other company offer more than what they offer?

  5. Working environment or high salary?

  6. Given a linked list with loop, how would you find the starting point of the loop ?

  7. Find a number a matrix mat[m][n] where all the rows and columns are sorted non-decreasingly. What will be the complexity of the solution

  8. Given an array of integers, print all possible permutations. Also explain your approach

  9. Design a Stack DS that also prints in O(1) the minimum element you pushed in the stack

  10. You have a stream of bytes from which you can read one byte at a time. You only have enough space to store one byte. After processing those bytes, you have to return a random byte. Note: The probability of picking any one of those bytes should be equal

  11. Find if a given Binary Tree is BST or not

  12. Devise an algorithm to determine the Nth-to-Last element in a singly linked list of unknown length. If N = 0, then your algorithm must return the last element. You should parse the list only once

  13. Find angle between hour hand and minute hand in clock if time is given? Write a program or pseudo code?

  14. A hash function was written to convert a string into a hash. Write a un-hash function to revert it(from hash to string)?

  15. Find if a given directed graph is cyclic or not

  16. A lot of discussion on my resume, experience etc

  17. Parse the XML? and store the output in JSON. Discussed different approaches?

  18. Print prime numbers in a given range and optimize the solution?

  19. How to write a Connection class to MySQL database using PHP?

  20. What are the different types of error in php?

  21. How session works in php?

  22. Find missing element in an array of elements from 0 to n-1?

  23. Write a regex for email validation?

  24. Write a singleton class in php?

  25. WAP to get smallest plindron number larger than the given no?

  26. WAP to check if linked list elements is a palindrome without using any extra space?

  27. Find the first non repetitive character in a string?

  28. What is connection pooling

  29. How to increase php memory at run time, if it exhausts?

  30. What all we can do with php.ini?

Companies that ask Software Developer questions