Add office photos
Employer?
Claim Account for FREE

Times Internet

3.6
based on 644 Reviews
Filter interviews by

20+ Fabcare And Facade Interview Questions and Answers

Updated 5 Feb 2024
Popular Designations
Q1. Puzzle

There are 20 red balls and 16 blue balls in a bag. Any 2 balls are removed at each step and are replaced with a new ball on the basis of the following conditions:
If they are of the same color, then they a...read more

Add your answer
Q2. First Missing Positive

You are given an array 'ARR' of integers of length N. Your task is to find the first missing positive integer in linear time and constant space. In other words, find the lowest positive in...read more

View 5 more answers
Q3. Clone Linked List with Random Pointer

Given a linked list having two pointers in each node. The first one points to the next node of the list, however, the other pointer is random and can point to any node of th...read more

View 4 more answers
Q4. Binary Array Sorting

A binary array is an array consisting of only 0s and 1s.

You are given a binary array "arr" of size ‘N’. Your task is to sort the given array and return this array after sorting.

Input Forma...read more

View 3 more answers
Discover Fabcare And Facade interview dos and don'ts from real experiences
Q5. Largest Prime Factor

You are given a positive integer ‘n’. Your task is to find the largest prime factor of this given positive integer.

Note :
If there is no prime factor of a given integer, then print -1. 
Inp...read more
View 3 more answers
Q6. Delete Node In BST

You have been given a Binary Search Tree of integers with ‘N’ nodes. You are also given data of a node of this tree. Your task is to delete the given node from the BST.

A binary search tree (B...read more

View 3 more answers
Are these interview questions helpful?

Q7. 20 red balls and 16 blue balls are present in a bag. 2 balls are removed, if they are of the same color, then they are replaced by a red ball. If they are of different color, then they are replaced with a blue ...

read more
Ans.

Balls are removed and replaced based on color. Find the last ball remaining.

  • Start with 20 red and 16 blue balls

  • Remove 2 balls and replace based on color

  • Repeat until only one ball remains

Add your answer
Q8. Insert Into A Binary Search Tree

You have been given a root node of the binary search tree and a positive integer value. You need to perform an insertion operation i.e. inserting a new node with the given value ...read more

View 3 more answers
Share interview questions and help millions of jobseekers 🌟
Q9. Puzzle

You are provided with 8 identical balls and a measuring instrument. 7 of the eight balls are equal in weight and one of the eight given balls is defective and weighs heavier. The task is to find the defec...read more

Add your answer

Q10. Find the second largest prime number from a given array of positive integers. Also return it's index in most optimal way

Ans.

Find the second largest prime number and its index from an array of positive integers.

  • Iterate through the array and check if each number is prime

  • Store the largest and second largest prime numbers found so far

  • Also store their indices

  • Return the second largest prime number and its index

Add your answer

Q11. If a person travels from point A to point B at 20 km/h and returns at 30 km/h, calculate the average speed without using pen and paper.

Ans.

The average speed can be calculated by taking the harmonic mean of the two speeds.

  • To calculate the harmonic mean, divide the sum of the speeds by the reciprocal of the sum of their reciprocals.

  • In this case, the harmonic mean can be calculated as 2/(1/20 + 1/30) = 24 km/h.

Add your answer

Q12. Which data structure would i use to program a jigsaw puzzle program and what methods would i use to solve the puzzle

Ans.

The data structure to program a jigsaw puzzle program would be a graph.

  • Use a graph data structure to represent the puzzle pieces and their connections.

  • Each puzzle piece can be represented as a node in the graph.

  • Edges between nodes represent the connections between puzzle pieces.

  • To solve the puzzle, use graph traversal algorithms like depth-first search or breadth-first search.

  • Apply puzzle-solving strategies like finding corner pieces first or matching edge colors.

Add your answer

Q13. Given 8 balls of the same properties and one of these balls is defective and is heavier than the others. Calculate the minimum no. of steps to find the defective ball

Ans.

The minimum number of steps to find the defective ball is 2.

  • Divide the 8 balls into 3 groups of 3, 3, and 2 balls.

  • Compare the weights of the two groups of 3 balls.

  • If one group is heavier, divide it into 2 balls and compare their weights.

  • If the two balls have different weights, the heavier ball is the defective one.

  • If the two balls have the same weight, the remaining ball in the first group of 3 is the defective one.

Add your answer

Q14. Given an array of positive and negative integers, find the first missing positive number in the most optimal way

Ans.

Find the first missing positive number in an array of positive and negative integers.

  • Sort the array in ascending order

  • Iterate through the sorted array and find the first positive number that is missing

  • If no positive number is missing, return the next positive number after the largest positive number in the array

Add your answer
Q15. Puzzle

If a person travels from point A to point B at 20 km/h and returns at 30 km/h, calculate the average speed without using pen and paper.

Add your answer

Q16. What is operator overloading?. Give an example

Ans.

Operator overloading is the ability to redefine operators for custom classes.

  • Allows operators to be used with custom classes

  • Example: '+' operator can be used to concatenate strings

  • Can improve readability and simplify code

Add your answer
Q17. OOPS Question

What is operator overloading?

Add your answer
Q18. OOPS Question

Differentiate between method overloading and method overriding

Add your answer
Q19. OOPS Question

What is Polymorphism?

Add your answer

Q20. Differentiate between method overloading and method overriding

Ans.

Method overloading is having multiple methods with the same name but different parameters. Method overriding is having a method in a subclass with the same name, return type, and parameters as a method in its superclass.

  • Method overloading is achieved within the same class.

  • Method overriding occurs in a subclass that inherits from a superclass.

  • Method overloading is determined at compile-time based on the number, type, and order of parameters.

  • Method overriding is determined at r...read more

Add your answer
Q21. DS Question

What is a BST?

Add your answer

Q22. What is polymorphism with examples

Ans.

Polymorphism is the ability of an object to take on many forms. It allows objects of different classes to be treated as the same type.

  • Polymorphism is achieved through method overriding and method overloading.

  • Method overriding allows a subclass to provide a specific implementation of a method that is already defined in its superclass.

  • Method overloading allows multiple methods with the same name but different parameters to be defined in a class.

  • Polymorphism enables code reusabi...read more

Add your answer

Q23. Delete a Node in Linked list.

Ans.

To delete a node in a linked list, we need to find the node and update the pointers of its previous and next nodes.

  • Find the node to be deleted by traversing the linked list

  • Update the pointers of the previous and next nodes to skip the node to be deleted

  • Free the memory occupied by the node to be deleted

Add your answer
Contribute & help others!
Write a review
Share interview
Contribute salary
Add office photos
Share an Interview
Stay ahead in your career. Get AmbitionBox app
qr-code
Helping over 1 Crore job seekers every month in choosing their right fit company
70 Lakh+

Reviews

5 Lakh+

Interviews

4 Crore+

Salaries

1 Cr+

Users/Month

Contribute to help millions
Get AmbitionBox app

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