Tip 1: DSA
Tip 2: CS Fundamentals (mainly OOPS, DBMS)
Tip 1: Don’t include false information on your resume.
Tip 2: Be prepared with your resume.
Tip 3: Learn SD.
The test consists of APIT and CS fundamentals.
Who needs a BIOS to function properly?
Which of the following is not considered a real-time operating system?
Which of the following refers to the number of attributes in a relation?
What will be the output of the following C++ code?
#include <iostream>
#include <algorithm>
using namespace std;
int main() {
string s = "spaces in text";
s.erase(remove(s.begin(),
s.end(), ' '),
s.end());
cout << s << endl;
}
Just do a dry run.
Ans:- spacesintext
What will be the output of the following C++ code?
#include <iostream>
using namespace std;
int main(int argc, char const *argv[]) {
char s1[6] = "Hello";
char s2[6] = "World";
char s3[12] = s1 + " " + s2;
cout << s3; return 0;
}
Answer: Hello World
Explanation: There is no operation defined for the addition of character arrays in C++, hence the compiler throws an error as it does not understand what to do with this expression.
Which of the following is not a type of queue?
A) Priority Queue
B) Single-ended Queue
C) Circular Queue
A graph with an edge from each vertex to every other vertex is called a ___________.
The options remain the same:
a) Tightly Connected
b) Strongly Connected
c) Weakly Connected
d) Loosely Connected
Answer: a) Tightly Connected
A deck of 5 cards, each carrying a distinct number from 1 to 5, is shuffled thoroughly. Two cards are then removed one at a time from the deck. What is the probability that the two cards are selected, with the number on the first card being one higher than the number on the second card?
A) 1/5
B) 4/25
C) 1/4
D) 2/5
The probability that a given positive integer between 1 and 100 (both inclusive) is NOT divisible by 2, 3, or 5 is ______.
A) 0.259
B) 0.459
C) 0.325
D) 0.225
Two coding problems were asked in the interview.



Let’s say we have an array 'ARR' {10, 12, 20, 30, 25, 40, 32, 31, 35, 50, 60}. Then we have to find the subarray {30 , 25 , 40 , 32 , 31 , 35} and print its length = 5 as our output. Because, when we sort this subarray the whole array will be sorted.
The idea is as follows:
These two conditions can be easily checked by building two vectors:



The ‘ARR’ = [1, 2, -3, -4, 5], the subarray [5, 1, 2] has the maximum possible sum which is 8. This is possible as 5 is connected to 1 because ‘ARR’ is a circular array.
Calculate the maximum subarray sum (maxSum) using Kadane's algorithm.
Calculate the minimum subarray sum (minSum) using Kadane's algorithm by using min() instead of max().
Calculate the sum of all the elements in nums, denoted as totalSum.
If minSum == totalSum, return maxSum; otherwise, return max(maxSum, totalSum - minSum).

Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
What is recursion?