MakeMyTrip
Wipro Interview Questions and Answers
Q1. Combination Sum Problem Statement
Given an array of distinct positive integers ARR
and a non-negative integer 'B', find all unique combinations in the array where the sum is equal to 'B'. Numbers can be chosen ...read more
The task is to find all unique combinations in an array where the sum is equal to a given target sum, with elements in non-decreasing order.
Use backtracking to generate all possible combinations.
Sort the array to ensure elements are in non-decreasing order.
Keep track of the current combination and sum while exploring the array.
Recursively explore all possible combinations.
Return the valid combinations that sum up to the target sum.
Q2. Next Greater Number Problem Statement
Given a string S
which represents a number, determine the smallest number strictly greater than the original number composed of the same digits. Each digit's frequency from...read more
The task is to find the smallest number greater than the given number with the same set of digits.
Iterate from right to left to find the first digit that can be swapped with a larger digit to make the number greater.
Swap this digit with the smallest digit to its right that is larger than it.
Sort all digits to the right of the swapped digit in ascending order to get the smallest number.
If no such number exists, return -1.
Example: For input '56789', output '56798'.
Q3. Program to find all possible combinations of elements from two sets of arrays such that the sum of elements is equal to one of the elements in the array itself.
Program to find all possible combinations of elements from two sets of arrays such that the sum of elements is equal to one of the elements in the array itself.
Create two arrays of integers
Loop through both arrays and find all possible combinations
Check if the sum of elements is equal to any element in the array
Return all combinations that meet the criteria
Q4. Program to find the next bigger number for the given number by just interchanging it's digits.ex- for 533224, answer is 533242
Program to find the next bigger number for the given number by interchanging its digits.
Convert the number to a string to access individual digits
Start from the rightmost digit and find the first digit that is smaller than the digit to its right
Swap this digit with the smallest digit to its right that is greater than it
Sort the digits to the right of the swapped digit in ascending order
Convert the string back to a number and return
Q5. One java string question merge two strings diagonally.
Merge two strings diagonally in a Java array of strings.
Iterate through each row and column to merge characters diagonally
Keep track of the diagonal position to insert characters from both strings
Handle cases where strings have different lengths
Example: String 1: 'hello', String 2: 'world', Merged: 'hweolrllod'
Example: String 1: 'abc', String 2: '123', Merged: 'a1b2c3'
Q6. If you get 500 error how to debug.
To debug a 500 error, check server logs, review code changes, test API endpoints, and use debugging tools.
Check server logs for error details
Review recent code changes that may have caused the error
Test API endpoints using tools like Postman
Use debugging tools like Chrome DevTools or Firebug
Interview Process at Wipro
Top Senior QA Engineer Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month