Add office photos
Infibeam logo
Employer?
Claim Account for FREE

Infibeam

3.1
based on 37 Reviews
Filter interviews by
Designation

20+ Infibeam Interview Questions and Answers

Updated 5 Feb 2024
Popular Designations

Q1. Which language do you prefer to code in? "Have you read The C Programming Language book by Dennis Retchie?" Which technical book have you read recently?.-So you like C, have you ever thought of bringing up the...

read more
Ans.

Yes, I prefer coding in C and have read The C Programming Language book. I have also explored the concept of Inheritance in C.

  • I find C to be a powerful and efficient language for system programming.

  • Yes, I have read The C Programming Language book by Dennis Retchie and found it to be a great resource.

  • Recently, I have been exploring the concept of Inheritance in C through various online resources and tutorials.

  • While C does not have built-in support for Inheritance, it is possib...read more

Add your answer
right arrow

Q2. How to optimize the code that you had written in aptitude test - It was a discussion, he helped me in solving the problem

Ans.

Optimizing code involves identifying and removing bottlenecks to improve performance.

  • Identify the parts of the code that are taking the most time to execute

  • Use efficient algorithms and data structures

  • Minimize the number of function calls and loops

  • Avoid unnecessary calculations or operations

  • Use caching or memoization to avoid repeating calculations

  • Profile the code to measure performance improvements

Add your answer
right arrow

Q3. What is the reason behind inventing the concept of inheritance? Write a program and explain

Ans.

Inheritance allows a class to inherit properties and methods from another class.

  • Inheritance promotes code reusability and saves time and effort in programming.

  • It allows for the creation of a hierarchy of classes with shared characteristics.

  • For example, a class Animal can be inherited by classes such as Dog, Cat, and Bird, which share common properties and methods.

  • Inheritance can be implemented using the 'extends' keyword in Java and the ':' symbol in Python.

Add your answer
right arrow

Q4. How to deploy web application on apache tomcat?-What is Collections in Java?

Ans.

To deploy a web application on Apache Tomcat, the application needs to be packaged as a WAR file and then deployed to the Tomcat server.

  • Create a WAR file of the web application

  • Copy the WAR file to the Tomcat webapps directory

  • Start the Tomcat server

  • Access the web application using the URL http://localhost:8080/

  • Collections in Java are classes that implement collections of objects, such as lists, sets, and maps

Add your answer
right arrow
Discover Infibeam interview dos and don'ts from real experiences

Q5. Gave a puzzle (find the heaviest ball amongst 8 balls in an optimized way). Tell the logic and write code for it.-write Create, Update, Delete, Insert, Select, Join SQL queries for a given problem

Ans.

Optimized way to find the heaviest ball amongst 8 balls puzzle and SQL queries

  • Use binary search approach to divide the balls into groups and weigh them

  • Repeat the process with the heavier group until the heaviest ball is found

  • For SQL queries, use appropriate syntax for each operation and join tables based on common columns

  • Example SQL queries: INSERT INTO table_name (column1, column2, column3) VALUES (value1, value2, value3), SELECT column1, column2 FROM table_name WHERE condit...read more

Add your answer
right arrow

Q6. What is the drawback of global variables?

Ans.

Global variables can lead to unexpected changes and make debugging difficult.

  • Global variables can be accessed and modified from any part of the code, making it difficult to track changes.

  • They can cause naming conflicts if multiple variables with the same name are used in different parts of the code.

  • Using global variables can make it harder to test and debug code, as it can be difficult to isolate the cause of errors.

  • They can also lead to security vulnerabilities if sensitive ...read more

Add your answer
right arrow
Are these interview questions helpful?

Q7. Why using 'goto' is a bad programming practice?

Ans.

Using 'goto' can make code hard to read, maintain and debug.

  • Goto statements can create spaghetti code that is difficult to follow.

  • It can make it harder to understand the flow of the program.

  • It can also make debugging more difficult.

  • There are usually better alternatives to using goto, such as using loops or functions.

  • Some programming languages, such as Java and Python, do not even have a goto statement.

  • Using goto can also make it harder to reuse code in other parts of the prog...read more

Add your answer
right arrow

Q8. Program to find the lowest common ancestor of two nodes in binary search tree as well as binary tree. I was also asked to give the brute force approach for the same

Ans.

Program to find lowest common ancestor of two nodes in binary search tree and binary tree with brute force approach.

  • For binary search tree, traverse from root to both nodes and store the path. Then compare paths to find LCA.

  • For binary tree, traverse from root to both nodes and store the path. Then compare paths to find LCA.

  • Brute force approach involves checking each node's descendants to see if they contain both nodes.

  • Time complexity for brute force approach is O(n^2) for wor...read more

Add your answer
right arrow
Share interview questions and help millions of jobseekers 🌟
man with laptop

Q9. Given an unsorted array of numbers, find two numbers which add up to the given sum in O(n)

Ans.

Find two numbers in an unsorted array that add up to a given sum in O(n)

  • Use a hash table to store the difference between the sum and each element in the array

  • Iterate through the array and check if the current element is in the hash table

  • If it is, return the current element and the corresponding difference

  • If not, add the current element to the hash table

Add your answer
right arrow

Q10. What are implicit objects in JSP?

Ans.

Implicit objects are pre-defined objects in JSP that can be accessed without being explicitly declared.

  • Implicit objects are created by the JSP container during the translation phase.

  • They can be accessed using predefined names such as request, response, session, application, out, pageContext, config, and exception.

  • For example, the request object can be used to retrieve parameters from a form or URL.

  • The session object can be used to store and retrieve user-specific data across ...read more

Add your answer
right arrow

Q11. What is Liskov substitution principle?

Ans.

Liskov substitution principle is a principle in object-oriented programming that states that objects of a superclass should be able to be replaced with objects of its subclasses without affecting the correctness of the program.

  • Subtypes must be substitutable for their base types

  • Derived classes must not change the behavior of the base class

  • Violating the principle can lead to unexpected behavior and errors

  • Example: A square is a rectangle, but if the Square class overrides the se...read more

Add your answer
right arrow

Q12. Explain OOPs concepts with a program for each

Ans.

Explanation of OOPs concepts with programs

  • Encapsulation: Wrapping data and functions into a single unit. Example: Class in Java

  • Abstraction: Hiding implementation details and showing only necessary information. Example: Abstract class in C#

  • Inheritance: Acquiring properties and behavior of a parent class. Example: Child class extending parent class in Python

  • Polymorphism: Ability of an object to take many forms. Example: Method overloading in Java

Add your answer
right arrow

Q13. Name a web server and an application server

Ans.

Apache is a popular web server and Tomcat is a widely used application server.

  • Apache is an open-source web server that supports multiple operating systems and is known for its stability and security.

  • Tomcat is a Java-based application server that is used to deploy Java web applications and supports servlets and JSPs.

  • Other popular web servers include Nginx and Microsoft IIS.

  • Other popular application servers include JBoss and WebSphere.

  • Web servers handle HTTP requests and respon...read more

Add your answer
right arrow

Q14. Now write an optimized version of that code

Ans.

Optimized version of given code

  • Use efficient data structures and algorithms

  • Avoid unnecessary loops and conditions

  • Minimize function calls and variable assignments

Add your answer
right arrow

Q15. Program to print the elements of a matrix in spiral order recursively

Ans.

Program to print matrix elements in spiral order recursively

  • Create a recursive function to print the elements in spiral order

  • Define the boundaries of the matrix and traverse the matrix in spiral order

  • Call the recursive function to print the elements in spiral order

  • Handle edge cases such as empty matrix or matrix with only one row/column

Add your answer
right arrow

Q16. Program to print all ancestors of a node in a binary tree

Ans.

Program to print all ancestors of a node in a binary tree

  • Create a recursive function to traverse the binary tree

  • Check if the current node is the target node

  • If yes, print all the nodes in the call stack

  • If not, recursively call the function for left and right subtrees

Add your answer
right arrow

Q17. Write a code for dynamic polymorphism

Ans.

Dynamic polymorphism is achieved through virtual functions and inheritance in object-oriented programming.

  • Create a base class with virtual functions

  • Create derived classes that override the virtual functions

  • Use pointers or references of the base class to call the virtual functions

  • The appropriate derived class function will be called based on the object being pointed to or referred to

Add your answer
right arrow

Q18. Program to implement Dijkstra’s algorithm

Ans.

Dijkstra's algorithm finds shortest path between nodes in a graph

  • Create a graph with nodes and edges

  • Initialize distances from source node to all other nodes as infinity

  • Set distance from source node to itself as 0

  • Create a set of unvisited nodes

  • While unvisited set is not empty, select node with minimum distance

  • For each neighbor of selected node, calculate distance from source node

  • If calculated distance is less than current distance, update distance

  • Mark selected node as visited

  • R...read more

Add your answer
right arrow

Q19. Program to implement Floyd­Warshall’s agorithm

Ans.

Floyd-Warshall's algorithm is used to find the shortest path between all pairs of vertices in a weighted graph.

  • Create a 2D array to store the distances between all pairs of vertices.

  • Initialize the array with the weights of the edges in the graph.

  • Use nested loops to iterate over all pairs of vertices and update the distances if a shorter path is found through a third vertex.

  • The final array will contain the shortest distances between all pairs of vertices.

Add your answer
right arrow

Q20. Program to swap two pointers

Ans.

A program to swap two pointers.

  • Declare two pointers of the same data type

  • Assign the first pointer to a temporary variable

  • Assign the second pointer to the first pointer

  • Assign the temporary variable to the second pointer

Add your answer
right arrow

Q21. Explain indexing in DBMS

Ans.

Indexing is a technique used in DBMS to improve the performance of queries.

  • Indexing creates a separate data structure that allows faster retrieval of data.

  • It works by creating a pointer to the location of data in the table.

  • Indexes can be created on one or more columns of a table.

  • Types of indexing include B-tree, hash, and bitmap indexing.

  • Indexes can also be clustered or non-clustered.

  • Clustered indexes determine the physical order of data in a table.

  • Non-clustered indexes creat...read more

Add your answer
right arrow

Q22. Explain B and B+ trees

Ans.

B and B+ trees are data structures used for efficient searching and sorting of large datasets.

  • B trees are balanced trees used for disk-based storage systems.

  • B+ trees are similar to B trees but have all data stored in the leaf nodes for faster searching.

  • B trees have a variable number of keys per node, while B+ trees have a fixed number.

  • B trees have a higher fanout than B+ trees, making them more efficient for smaller datasets.

  • B+ trees are commonly used in databases and file sy...read more

Add your answer
right arrow
Contribute & help others!
Write a review
Write a review
Share interview
Share interview
Contribute salary
Contribute salary
Add office photos
Add office photos

Interview Process at Infibeam

based on 1 interviews
Interview experience
1.0
Bad
View more
interview tips and stories logo
Interview Tips & Stories
Ace your next interview with expert advice and inspiring stories

Top Interview Questions from Similar Companies

Bharti Airtel Logo
4.0
 • 376 Interview Questions
BARC Logo
4.4
 • 218 Interview Questions
Eviden Logo
3.6
 • 168 Interview Questions
Lenskart Logo
3.2
 • 165 Interview Questions
MRF Tyres Logo
3.7
 • 139 Interview Questions
Globant Logo
3.8
 • 135 Interview Questions
View all
Recently Viewed
INTERVIEWS
Empower
5.6k top interview questions
REVIEWS
Flipkart
No Reviews
REVIEWS
Empower
No Reviews
INTERVIEWS
Flipkart
No Interviews
SALARIES
Flipkart
SALARIES
Infibeam
LIST OF COMPANIES
Infosys
Locations
SALARIES
Infibeam
REVIEWS
Infibeam
No Reviews
INTERVIEWS
Infibeam
No Interviews
Top Infibeam Interview Questions And Answers
Share an Interview
Stay ahead in your career. Get AmbitionBox app
play-icon
play-icon
qr-code
Helping over 1 Crore job seekers every month in choosing their right fit company
75 Lakh+

Reviews

5 Lakh+

Interviews

4 Crore+

Salaries

1 Cr+

Users/Month

Contribute to help millions

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2024 Info Edge (India) Ltd.

Follow us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter