i
Mystifly Consulting
Filter interviews by
Clear (1)
A linked list is a data structure that consists of a sequence of nodes, where each node contains a reference to the next node.
Advantages of linked list:
- Dynamic size: Linked lists can grow or shrink as needed.
- Efficient insertion and deletion: Adding or removing elements from a linked list is faster than an array.
- Flexibility: Linked lists can be easily modified and reorganized.
Representation of a linked list:
- Each...
Code for Fibonacci number using recursion
Define a function that takes an integer as input
If the input is 0 or 1, return the input
Else, return the sum of the function called with input-1 and input-2
Call the function with the desired input
Check if a sorted array from 1 to n has a repeated number.
Iterate through the array and check if the current element is equal to the next element.
If yes, return true. If no, continue iterating.
If the loop completes without finding a repeated element, return false.
Print a string with all occurrences of the first character first.
Loop through the string and count the occurrences of the first character.
Print the first character that many times, then print the rest of the string.
Print Fibonacci series using iterative or recursive approach.
Iterative approach: Use a loop to generate the series.
Recursive approach: Use a function to call itself to generate the series.
Start with 0 and 1, then add the previous two numbers to get the next number.
The series goes like this: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, ...
The series can be generated up to a certain limit or until a certain number is re
OOPS concepts are the principles of Object-Oriented Programming that focus on encapsulation, inheritance, polymorphism, and abstraction.
Encapsulation: bundling of data and methods that operate on that data within a single unit
Inheritance: ability of a class to inherit properties and methods from a parent class
Polymorphism: ability of objects to take on many forms or have multiple behaviors
Abstraction: hiding of complex...
Pillars of OOPS are the fundamental principles of Object-Oriented Programming.
Abstraction: Hiding implementation details and showing only necessary information.
Encapsulation: Binding data and functions together to protect data from outside interference.
Inheritance: Acquiring properties and behavior of a parent class by a child class.
Polymorphism: Ability of objects to take multiple forms or have multiple behaviors.
OOPS is important for code reusability, maintainability, and extensibility.
Encapsulation ensures data security and prevents unwanted access.
Inheritance allows for code reuse and reduces redundancy.
Polymorphism enables flexibility and extensibility of code.
Abstraction simplifies complex systems and hides implementation details.
OOPS promotes modular design and improves code maintainability.
OOPS facilitates team collabora...
Classes are templates for creating objects. Objects are instances of classes that have their own properties and methods.
Classes define the properties and methods that objects of that class will have
Objects are instances of classes that can be created and manipulated in code
Classes and objects are fundamental concepts in object-oriented programming
Example: A class 'Car' can have properties like 'make', 'model', 'year',
A constructor is a special method that is used to initialize objects in a class.
Constructors have the same name as the class they are in
They are called automatically when an object is created
They can take parameters to set initial values for object properties
Abstraction and interface are both used to achieve abstraction in programming.
Abstraction is the process of hiding implementation details while showing only the necessary information to the user.
Interface is a blueprint for a class that defines a set of methods and properties that the class must implement.
Abstraction can be achieved through abstract classes and interfaces.
Abstraction is a concept while interface is a l...
Abstraction is a way of hiding implementation details and showing only necessary information to the user.
Abstract class is a class that cannot be instantiated and can have both abstract and non-abstract methods.
Interface is a collection of abstract methods and constants that can be implemented by any class.
Abstract classes can have constructors, while interfaces cannot.
A class can implement multiple interfaces, but can...
Types of inheritance in software engineering
Single inheritance: a class inherits from only one parent class
Multiple inheritance: a class inherits from multiple parent classes
Multilevel inheritance: a class inherits from a derived class, which in turn inherits from another class
Hierarchical inheritance: multiple classes inherit from a single parent class
Hybrid inheritance: a combination of multiple and multilevel inheri
Structures are value types while classes are reference types.
Structures are allocated on stack while classes are allocated on heap.
Structures do not support inheritance while classes do.
Structures cannot have destructors while classes can.
Structures are used for small data structures while classes are used for larger, more complex objects.
Structures are passed by value while classes are passed by reference.
Constructor and destructor are special member functions in a class that are used to initialize and destroy objects respectively.
Constructor is called when an object is created and is used to initialize the object's data members.
Destructor is called when an object is destroyed and is used to free up any resources allocated by the object.
Constructor has the same name as the class and no return type, while destructor has ...
Encapsulation is the process of hiding implementation details and exposing only necessary information.
Encapsulation is achieved through access modifiers like public, private, and protected.
It helps in achieving data abstraction and information hiding.
It prevents unauthorized access to the internal state of an object.
Example: A class with private variables and public methods to access them.
To add a new column to an existing table, use the ALTER TABLE command.
Use the ALTER TABLE command followed by the table name.
Use the ADD keyword followed by the new column name and its data type.
Example: ALTER TABLE table_name ADD column_name data_type;
Make sure to specify any additional constraints or default values for the new column.
Query to return customers who joined the company in March.
Use the WHERE clause to filter the join date by month
Assuming the join date is stored in a 'join_date' column
Example: SELECT * FROM customers WHERE MONTH(join_date) = 3
The OSI model is a conceptual model that characterizes and standardizes the communication functions of a telecommunication or computing system.
The seven layers are: Physical, Data Link, Network, Transport, Session, Presentation, and Application.
Each layer has a specific function and communicates with the layers above and below it.
The Physical layer deals with the physical transmission of data.
The Data Link layer provid...
The application layer uses various protocols such as HTTP, FTP, SMTP, etc.
HTTP (Hypertext Transfer Protocol) is used for web browsing
FTP (File Transfer Protocol) is used for file transfer
SMTP (Simple Mail Transfer Protocol) is used for email communication
POP3 (Post Office Protocol version 3) is used for retrieving emails
IMAP (Internet Message Access Protocol) is used for accessing emails on a server
DNS (Domain Name Sys...
TCP is a connection-oriented protocol while UDP is connectionless.
TCP provides reliable, ordered, and error-checked delivery of data while UDP does not guarantee any of these.
TCP is slower but more reliable while UDP is faster but less reliable.
TCP is used for applications that require high reliability and accuracy while UDP is used for applications that require speed and efficiency.
Examples of TCP-based applications i...
To measure 4 minutes using two hourglasses of 11 and 7 minutes, start both hourglasses simultaneously and flip the 7-minute hourglass when it runs out. When the 11-minute hourglass runs out, 4 minutes will have passed.
Start both hourglasses simultaneously
When the 7-minute hourglass runs out, flip it
When the 11-minute hourglass runs out, 4 minutes will have passed
Program an ATM machine to dispense only 500 and 100 notes and count their number.
Create a function to dispense money
Use a loop to count the number of notes
Use if statements to check if the amount is divisible by 500 or 100
Display the total number of notes dispensed
Program to find binary format of 4 and 7.
Convert decimal numbers to binary using bitwise operator.
Print the binary format of the numbers.
Use printf or cout to display the output.
Print Fibonacci Series between two given numbers iteratively and recursively.
Iteratively, use a loop to generate Fibonacci numbers until the upper limit is reached.
Recursively, use a function to generate Fibonacci numbers until the upper limit is reached.
Store the generated Fibonacci numbers in an array and print them between the given numbers.
All possible ways to traverse a tree.
Pre-order traversal: root, left, right
In-order traversal: left, root, right
Post-order traversal: left, right, root
Level-order traversal: breadth-first search
Reverse level-order traversal: depth-first search
To find a loop in a linked list, use Floyd's cycle-finding algorithm.
Floyd's algorithm uses two pointers, one moving at twice the speed of the other.
If there is a loop, the faster pointer will eventually catch up to the slower one.
To determine the start of the loop, reset one pointer to the beginning and move both at the same speed.
Height of a tree refers to the maximum number of edges from the root node to any leaf node in the tree.
Height of a tree can be calculated recursively by finding the height of left and right subtrees and adding 1 to the maximum of the two heights.
Height of a tree can also be calculated iteratively using level order traversal.
Height of a tree with only one node is 0.
Height of an empty tree is -1.
I would use a Linked List data structure for frequent insertion and deletion operations.
Linked Lists have constant time complexity for insertion and deletion operations.
Arrays have a linear time complexity for these operations.
Doubly Linked Lists allow for efficient deletion of nodes.
Examples of use cases include implementing a queue or stack.
Find the element that occurs only once in an array of numbers from 1 to n with all other numbers occurring twice.
Use XOR operation to find the unique element.
Iterate through the array and XOR each element with the result.
The final result will be the unique element.
Abstraction: hiding implementation details. Inheritance: creating new classes from existing ones. Polymorphism: same method, different behavior.
Abstraction: Focuses on what an object does instead of how it does it.
Inheritance: Allows a new class to be based on an existing class.
Runtime Polymorphism: Same method can be used for different objects, with different behavior.
Example: A car is an abstraction of a vehicle. Sed...
DBMS stands for Database Management System. It is a software system that manages and organizes data in a database.
DBMS is used to create, modify, and delete databases and their objects.
It provides a way to store, retrieve, and manipulate data efficiently.
Examples of DBMS include MySQL, Oracle, SQL Server, and MongoDB.
Primary key uniquely identifies a record in a table, while unique key ensures uniqueness of a column.
Primary key can't have null values, while unique key can have one null value.
A table can have only one primary key, but multiple unique keys.
Primary key is used as a foreign key in other tables, while unique key is not.
Example: Primary key - employee_id in employee table. Unique key - email in employee table.
Constraints are limitations or restrictions that are put on a system or process.
Constraints can be related to time, resources, budget, or technology.
They can be imposed by external factors such as regulations or internal factors such as company policies.
Examples of constraints in software development include limited memory or processing power, compatibility with existing systems, and security requirements.
OS stands for Operating System. It is responsible for managing computer hardware and software resources.
OS is the interface between the user and the computer hardware.
It manages memory, processes, and input/output devices.
Examples of OS include Windows, macOS, and Linux.
OS is responsible for providing security and managing user accounts.
It also provides a platform for running applications and software.
Multithreading is the ability of a CPU to execute multiple threads concurrently.
Multithreading allows for better utilization of CPU resources.
It can improve application performance by allowing multiple tasks to run simultaneously.
Multithreading can also lead to synchronization issues and race conditions.
Examples of multithreaded applications include web servers, video games, and media players.
Multithreading is the ability of a CPU to run multiple threads concurrently, while multitasking is the ability of an OS to run multiple processes concurrently.
Multithreading is at the CPU level, while multitasking is at the OS level.
Multithreading allows multiple threads to share the same memory space, while multitasking requires separate memory spaces for each process.
Multithreading is used for improving performance a...
I am a software engineer with 5 years of experience in developing web applications using Java and JavaScript.
I have a strong background in object-oriented programming and software development principles.
I am proficient in Java, JavaScript, and related frameworks such as Spring and React.
I have experience in designing and implementing RESTful APIs.
I am familiar with Agile methodologies and have worked in Scrum teams.
I h...
My strength is problem-solving and my weakness is perfectionism.
Strength: Strong problem-solving skills
Strength: Ability to work well in a team
Weakness: Perfectionism
Weakness: Difficulty in delegating tasks
Mystify is likely a function or method that performs a complex or obscure operation.
Mystify could be encrypting or obfuscating data.
It might be performing a transformation or manipulation on data.
Mystify could be generating random or unpredictable outputs.
I want to join your company because of its reputation for innovation and the opportunity to work on cutting-edge projects.
Reputation for innovation
Opportunity to work on cutting-edge projects
You should hire me because I have a strong technical background, excellent problem-solving skills, and a passion for software development.
I have a Bachelor's degree in Computer Science and extensive experience in software development.
I have a deep understanding of various programming languages and frameworks, including Java, Python, and JavaScript.
I have a proven track record of delivering high-quality software solutio...
I applied via Job Portal and was interviewed before Aug 2021. There were 2 interview rounds.
Top trending discussions
I appeared for an interview before Feb 2021.
Round duration - 90 minutes
Round difficulty - Medium
Questions on aptitude, English, logical reasoning, C/C++ and 5 coding ques. (only pseudo code).
Bob and his wife are in the famous 'Arcade' mall in the city of Berland. This mall has a unique way of moving between shops using trampolines. Each shop is laid out in a st...
Find the minimum number of trampoline jumps Bob needs to make to reach the final shop, or return -1 if it's impossible.
Use Breadth First Search (BFS) algorithm to find the minimum number of jumps required.
Keep track of the visited shops to avoid revisiting them.
If a shop has an Arr value of 0, it is impossible to reach the final shop.
Return -1 if the final shop cannot be reached.
Given two strings, S
and X
, your task is to find the smallest substring in S
that contains all the characters present in X
.
S = "abdd", X = "bd"
Find the smallest substring in S that contains all characters in X.
Use a sliding window approach to find the smallest window in S containing all characters of X.
Maintain a hashmap to keep track of characters in X and their frequencies in the current window.
Slide the window to the right, updating the hashmap and shrinking the window until all characters in X are present.
Return the smallest window found.
Example: S = 'abd
You need to determine all possible paths for a rat starting at position (0, 0) in a square maze to reach its destination at (N-1, N-1). The maze is represented as an N*N ma...
Find all possible paths for a rat in a maze from start to destination.
Use backtracking to explore all possible paths in the maze.
Keep track of visited cells to avoid revisiting them.
Return paths in alphabetical order as a list of strings.
Round duration - 60 minutes
Round difficulty - Easy
Questions based on OOPS were asked in this round.
A virtual function is a function in a base class that is declared using the keyword 'virtual' and can be overridden by a function with the same signature in a derived class.
Virtual functions allow for dynamic polymorphism in C++
They are used in inheritance to achieve runtime polymorphism
Virtual functions are declared in a base class and can be overridden in derived classes
They are called based on the type of object bei...
Types of polymorphism in OOP include compile-time (method overloading) and runtime (method overriding) polymorphism.
Compile-time polymorphism is achieved through method overloading, where multiple methods have the same name but different parameters.
Runtime polymorphism is achieved through method overriding, where a subclass provides a specific implementation of a method that is already defined in its superclass.
Polymor...
Deep copy creates a new object and recursively copies all nested objects, while shallow copy creates a new object and copies only the references to nested objects.
Deep copy creates a new object and copies all nested objects, while shallow copy creates a new object and copies only the references to nested objects.
In deep copy, changes made to the original object do not affect the copied object, while in shallow copy, ch...
Round duration - 30 minutes
Round difficulty - Easy
HR round with typical behavioral problems.
Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
I appeared for an interview before Feb 2021.
Round duration - 65 minutes
Round difficulty - Easy
There were 2 sections –
Aptitude and Logical Reasoning and MCQ based on Java question ,C++, coding for 20 min and 45 min respectively.
Section A- Not very difficult to clear this round although less time was a problem.
Section B- It contains 15 multiple choice question on c/c++,java and 4 simple coding questions
Determine if a given singly linked list of integers forms a cycle or not.
A cycle in a linked list occurs when a node's next
points back to a previous node in the ...
Detect if a singly linked list forms a cycle by checking if a node's next pointer points back to a previous node.
Traverse the linked list using two pointers, one moving at double the speed of the other.
If the two pointers meet at any point, there is a cycle in the linked list.
Use Floyd's Cycle Detection Algorithm for O(N) time complexity and O(1) space complexity.
Round duration - 75 minutes
Round difficulty - Medium
It was an online coding test in which 3 coding question were given.
Given two strings, S
and X
, your task is to find the smallest substring in S
that contains all the characters present in X
.
S = "abdd", X = "bd"
Find the smallest substring in string S that contains all characters in string X.
Iterate through string S and keep track of characters in X found in a window
Use two pointers to maintain the window and slide it to find the smallest window
Return the smallest window containing all characters in X
Given a non-decreasing sorted array ARR
of N
positive numbers, determine the smallest positive integer that cannot be expressed as the sum of elements from...
Find the smallest positive integer that cannot be expressed as the sum of elements from any proper subset of a non-decreasing sorted array of positive numbers.
Start with the smallest possible integer that cannot be represented, which is 1.
Iterate through the array and update the smallest integer that cannot be represented.
If the current element is greater than the smallest integer that cannot be represented, return tha...
Given a square chessboard of size 'N x N', determine the minimum number of moves a Knight requires to reach a specified target position from its initial position...
Calculate the minimum number of moves a Knight needs to reach a target position on a chessboard.
Implement a function that takes knight's starting position, target position, and chessboard size as input
Use breadth-first search algorithm to find the shortest path for the Knight
Consider all possible 8 movements of the Knight on the chessboard
Return the minimum number of moves required for the Knight to reach the target po
Round duration - 60 minutes
Round difficulty - Easy
It started with a discussion on the programs given in coding round. They asked me about my interest field after that they directly jumped into Networking, Linux and Ethical Hacking part looking my interest domain. They asked me various question on networking and linux.
Then they asked me to code a simple c program
Given a singly linked list of integers, return the head of the reversed linked list.
Initial linked list: 1 -> 2 -> 3 -> 4 -> NULL
Reversed link...
Reverse a singly linked list of integers and return the head of the reversed linked list.
Iterate through the linked list and reverse the pointers to point to the previous node.
Keep track of the current, previous, and next nodes while reversing the linked list.
Update the head of the reversed linked list as the last node encountered during reversal.
FTP uses port number 21 and SMTP uses port number 25.
FTP uses port 21 for data transfer and port 20 for control information.
SMTP uses port 25 for email communication.
Understanding port numbers is important for network communication.
The OSI Model is a conceptual framework that standardizes the functions of a telecommunication or computing system into seven layers.
The OSI Model stands for Open Systems Interconnection Model.
It consists of seven layers: Physical, Data Link, Network, Transport, Session, Presentation, and Application.
Each layer has specific functions and communicates with the adjacent layers.
Example: Layer 1 (Physical) deals with physi...
To copy files in Linux, you can use the 'cp' command.
Use the 'cp' command followed by the source file and destination directory to copy a file.
To copy a directory and its contents, use the '-r' flag with the 'cp' command.
You can also use wildcards like '*' to copy multiple files at once.
Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
Find the subset of an array with the largest sum of continuous positive numbers.
Iterate through the array and keep track of the current sum and the maximum sum seen so far.
If the current element is positive, add it to the current sum. If it is negative, reset the current sum to 0.
Also keep track of the start and end indices of the maximum sum subset.
Return the subset using the start and end indices.
Find smallest substring in s1 containing all characters of s2.
Create a hash table of characters in s2
Use sliding window technique to find smallest substring in s1
Check if all characters in s2 are present in the substring
Update the smallest substring if a smaller one is found
Algorithm to reverse a linked list
Create a new empty linked list
Traverse the original linked list and insert each node at the beginning of the new list
Return the new list
Lazy loading is a technique used to defer the loading of non-critical resources until they are needed.
Advantages: faster initial page load, reduced bandwidth usage, improved user experience
Disadvantages: increased complexity, potential for slower subsequent page loads, difficulty with SEO
Examples: images, videos, and other media files can be loaded only when they are visible on the screen
Ajax is a technique for creating fast and dynamic web pages. AngularJS is a framework for building dynamic web applications, while jQuery is a library for simplifying HTML DOM traversal and manipulation.
Ajax stands for Asynchronous JavaScript and XML
It allows web pages to be updated asynchronously by exchanging data with a web server behind the scenes
AngularJS is a JavaScript framework that extends HTML with new attrib...
A traffic light system controls the flow of traffic at intersections.
The system consists of three lights: red, yellow, and green.
Each light has a specific duration for which it stays on.
The system also includes sensors to detect the presence of vehicles and pedestrians.
The duration of each light can be adjusted based on traffic patterns.
The system can be connected to a central control system for remote monitoring and m
I appeared for an interview before Feb 2021.
Round duration - 60 minutes
Round difficulty - Easy
Technical round with 3 problems based on DSA and Algorithms.
Given a non-decreasing sorted array ARR
of N
positive numbers, determine the smallest positive integer that cannot be expressed as the sum of elements from...
Find the smallest positive integer that cannot be expressed as the sum of elements from any proper subset of a given array.
Sort the array in non-decreasing order.
Iterate through the array and keep track of the smallest sum that can be formed.
If the next element in the array is greater than the current sum + 1, then the answer is the current sum + 1.
Return the answer as the smallest integer not representable as a subset
Given a singly linked list of integers, return the head of the reversed linked list.
Initial linked list: 1 -> 2 -> 3 -> 4 -> NULL
Reversed link...
Reverse a singly linked list of integers and return the head of the reversed linked list.
Iterate through the linked list and reverse the pointers to point to the previous node instead of the next node.
Use three pointers to keep track of the current, previous, and next nodes while reversing the linked list.
Update the head of the reversed linked list to be the last node encountered during the reversal process.
Given two strings S
and X
containing random characters, the task is to find the smallest substring in S
which contains all the characters present in X
.
The first...
The task is to find the smallest substring in string S which contains all the characters present in string X.
Iterate through string S and keep track of characters in X using a hashmap
Use two pointers to maintain a sliding window and find the smallest window containing all characters in X
Return the smallest window found
Round duration - 60 minutes
Round difficulty - Easy
Technical round with questions based on OOPS and Angular.
OOP concepts include inheritance, encapsulation, polymorphism, and abstraction.
Inheritance allows a class to inherit properties and behavior from another class.
Encapsulation restricts access to certain components of an object, protecting its integrity.
Polymorphism allows objects to be treated as instances of their parent class.
Abstraction hides the complex implementation details of an object and only shows the necessar
Round duration - 60 minutes
Round difficulty - Easy
Questions based on System Design, ajax, jquery were asked.
Designing a traffic light system involves creating a system that controls the flow of traffic at intersections.
Divide the traffic light system into three main lights: red, yellow, and green.
Implement timers to control the duration of each light.
Include sensors to detect the presence of vehicles and pedestrians.
Consider implementing a pedestrian crossing signal.
Integrate a central control system to coordinate the timing
AJAX allows for asynchronous communication between client and server without needing to reload the entire page.
AJAX stands for Asynchronous JavaScript and XML.
It allows for sending and receiving data from a server without reloading the entire page.
AJAX uses XMLHttpRequest object to make requests to the server.
It can update parts of a web page without requiring a full page reload.
Commonly used in web applications to pro
AngularJS is a full-fledged MVC framework for building dynamic web applications, while jQuery is a lightweight library for DOM manipulation and event handling.
AngularJS is a full-fledged MVC framework, providing features like two-way data binding, dependency injection, and routing.
jQuery is a lightweight library primarily used for DOM manipulation and event handling.
AngularJS is suitable for building single-page applic...
Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
I appeared for an interview in Aug 2016.
Some of the top questions asked at the Mystifly Consulting Software Engineer interview -
based on 6 reviews
Rating in categories
Senior Travel Consultant
46
salaries
| ₹3.7 L/yr - ₹7.2 L/yr |
Travel Consultant
24
salaries
| ₹3 L/yr - ₹5.5 L/yr |
Senior Accounts Executive
21
salaries
| ₹4.2 L/yr - ₹7.1 L/yr |
Software Engineer
18
salaries
| ₹5.5 L/yr - ₹20 L/yr |
Product Manager
15
salaries
| ₹26 L/yr - ₹41 L/yr |
Amadeus
Travelport
Sabre
Cleartrip