Springworks
20+ Zebronics Interview Questions and Answers
Q1. Number of Islands Problem Statement
You are provided with a 2-dimensional matrix having N
rows and M
columns, containing only 1s (land) and 0s (water). Your goal is to determine the number of islands in this ma...read more
Q2. Equilibrium Indices in a Sequence
You are given an array/list named 'SEQUENCE', which consists of 'N' integers. The task is to identify all equilibrium indices in this sequence.
Explanation:
An equilibrium inde...read more
The task is to find the equilibrium indices of a given sequence, where the sum of elements at lower indices is equal to the sum of elements at higher indices.
Iterate through the sequence and calculate the total sum of all elements
Initialize a left sum and right sum as 0
For each index, update the left sum and right sum and check if they are equal
If they are equal, add the index to the equilibrium indices
Return the equilibrium indices
Q3. Paint House Problem Statement
You have been given a set of 'N' houses, each house can be painted using one of three colors: green, red, or yellow. A cost matrix is provided with dimensions 'N' * 3, where each e...read more
Q4. Rearrange Linked List Problem Statement
Given a singly linked list in the form 'L1' -> 'L2' -> 'L3' -> ... 'Ln', your task is to rearrange the nodes to the form 'L1' -> 'Ln' -> 'L2' -> 'Ln-1', etc. You must not...read more
The task is to rearrange the nodes of a singly linked list in a specific order without altering the data of the nodes.
Iterate through the linked list to find the middle node using the slow and fast pointer technique.
Reverse the second half of the linked list.
Merge the first and reversed second half of the linked list alternatively to get the desired order.
Q5. Implementing Queue with Two Stacks
Your task is to implement a queue using two stacks. You are provided with ‘Q’ queries and need to handle them, where each query falls under one of these two operations:
- Enque...read more
Q6. Maximum Product Subarray Problem Statement
Given an array of integers, determine the contiguous subarray that produces the maximum product of its elements.
Explanation:
A subarray can be derived from the origin...read more
Q7. Divide String Problem Statement
You are given a string WORD
consisting of lowercase alphabets. Your task is to divide WORD
into N
strings of equal length.
Input:
The first line contains an integer 'T' represent...read more
Q8. Inorder Traversal of Binary Tree
You are provided with a Binary Tree composed of 'N' nodes, each holding integer values. Your task is to compute the Inorder traversal of this binary tree.
Example:
For the given...read more
The task is to find the in-order traversal of a given binary tree.
Implement a recursive function to perform in-order traversal of the binary tree
Start from the left subtree, then visit the root node, and finally visit the right subtree
Use an array to store the values of the nodes in the in-order traversal
Q9. Search in a Row-wise and Column-wise Sorted Matrix Problem Statement
You are given an N * N matrix of integers where each row and each column is sorted in increasing order. Your task is to find the position of ...read more
Given a sorted matrix, find the position of a target integer in the matrix.
Iterate through each row and column of the matrix
Compare the target integer with the current element
If the target integer is found, return the position
If the target integer is not found, return {-1, -1}
Q10. Matrix Chain Multiplication Problem
Given 'N' 2-dimensional matrices and an array ARR
of length N + 1
, where the first N
integers denote the number of rows in each matrix and the last integer represents the num...read more
Q11. Painting Fences Problem Statement
You are given ‘N’ fences. Your task is to compute the total number of ways to paint these fences using only 2 colors, such that no more than 2 adjacent fences have the same col...read more
The task is to find the total number of ways to paint fences using 2 colors such that at most 2 adjacent fences have the same color.
Use dynamic programming to solve the problem
Create a 2D array to store the number of ways to paint the fences
Initialize the base cases for the first two fences
Use recurrence relation to calculate the number of ways for the remaining fences
Return the result modulo 10^9 + 7
Q12. Roman Numeral to Integer Conversion
Convert a string representing a Roman numeral into its integer equivalent and return the result.
Explanation:
Roman numerals are represented by seven different symbols: I, V,...read more
Q13. Linear Probing in Hashing
Hashing is a technique to map large non-negative integers to smaller indices using a hash function. In the context of collision resolution in hash tables, 'Linear Probing' is employed,...read more
Q14. M-Coloring Problem Statement
Given an undirected graph as an adjacency matrix and an integer M
, determine whether you can color the vertices of the graph using at most M
colors such that no two adjacent vertice...read more
Q15. Internet Address Problem
You are given the task of reconstructing the address of an Internet resource from a given format.
Explanation:
The address format is:
is either "http" or "ftp".
is a non-em...read more
The task is to extract and print the internet resource address from a given string.
The internet resource address has a specific format:
:// .ru[/ ] The
can be either 'http' or 'ftp' The
is a non-empty string of lowercase English letters The
may or may not be present, and if present, it is a non-empty string of lowercase English letters If
is not present, the address has either two '/' characters (before the domain) or three (an extra one in front of the context)
Q16. Pair Sum Problem Statement
You are given an array of integers 'ARR' with a length 'N' and a specific integer 'Target'. Your objective is to determine and return all pairs of elements within the array whose sum ...read more
Q19. Projects and tech stack used
I have worked on various projects using different tech stacks including Java, Python, and JavaScript.
Developed a web application using Java Spring Boot framework
Created a data analysis tool using Python libraries such as Pandas and NumPy
Built a real-time chat application using JavaScript and Node.js
Implemented machine learning algorithms using Python's scikit-learn library
Worked on a mobile application using React Native framework
The inner join operation combines rows from two tables based on a common column (key).
Use the JOIN keyword in the SQL query to perform an inner join.
Specify the common column (key) in the ON clause of the join.
The result will contain only the matching rows from both tables.
Q21. what are some of the errors while submitting into p21
Errors while submitting into p21
Incorrect data format or structure
Missing required fields
Invalid data values
Network connectivity issues
Authorization/authentication problems
Q22. What is object orienteered programming.
Object oriented programming is a programming paradigm based on the concept of objects, which can contain data and code.
Objects are instances of classes, which define the structure and behavior of the objects.
Encapsulation, inheritance, and polymorphism are key principles of object oriented programming.
Example: Java, C++, Python are popular languages that support object oriented programming.
Q23. What do you know about oops
Object-oriented programming paradigm focusing on objects and classes
Encapsulation: Bundling data and methods that operate on the data into a single unit (object)
Inheritance: Ability of a class to inherit properties and behavior from another class
Polymorphism: Ability to present the same interface for different data types
Abstraction: Hiding the complex implementation details and showing only the necessary features
Q24. Tell me about encapsulation
Encapsulation is the concept of bundling data and methods that operate on the data into a single unit.
Encapsulation helps in hiding the internal state of an object and restricting access to it.
It allows for better control over the data by preventing outside interference.
Encapsulation also promotes code reusability and modularity.
Example: In object-oriented programming, classes encapsulate data fields and methods to operate on those fields.
Q25. different Events in java script
Events in JavaScript are actions or occurrences that happen in the browser that the code can respond to.
Events can be triggered by user actions (like clicking a button), browser actions (like page load), or system events (like a timer expiring)
Event listeners are used to listen for and respond to events
Common events include click, mouseover, keydown, submit, etc.
Q26. which domains have death details
Domains such as healthcare, insurance, and public health typically have death details.
Healthcare
Insurance
Public health
Q27. RCA - number of iphone users
To determine the number of iPhone users, conduct Root Cause Analysis (RCA) by analyzing sales data, market research, and user surveys.
Analyze sales data from Apple to determine the number of iPhones sold
Conduct market research to estimate market share of iPhones compared to other smartphones
Survey iPhone users to gather data on usage patterns and demographics
Top HR Questions asked in Zebronics
Interview Process at Zebronics
Top Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month