First Round: (Written)
- Maximum sum of non-contiguous elements in array
Input : 1 12 5 4 13 Output: 25
- Given an array of integers, find a combination of four elements in the array whose sum is equal to a given value X.
Input Array : 1 5 1 0 6 0 Input Sum: 7 Output : 1 (1 if present, else 0)
Second : (F2F)
- Discussion of above two questions.
- If a doubly linked list has pointers in the form of integers that represesnts memory location, and we want to manage only one reference for both prev and next node, how will the list be traversed.
- Rotate right a binary tree
Third : (F2F)
- Diameter of a binary tree
- How DNS lookup works
- SQL Query with 3 tables : Student, Class, Test
Input : Student : SID, CID, Name Class : CID, Cname Test : TestId, WeekId, SID, Marks
Write a query to print average marks classwise for each week
Output Example :
ClassName, WeekId, Avg_Marks Tenth, 1, 33 Eleventh, 1, 34 Tenth, 2, 45 Eleventh, 2, 21
Solution : select (select Cname from Class where CID = S.CID)ClassName, T.WeekId, AVG(T.Marks)
from Test T LEFT_JOIN Student S on T.SID=S.SID
group by ClassName, T.WeekId
- Design a Ludo/Snake&Ladders
If you like GeeksforGeeks and would like to contribute, you can also write an article and mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please write comments if you find anything incorrect, or you want to share more information about the topic discussed above
Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready. To complete your preparation from learning a language to DS Algo and many more, please refer Complete Interview Preparation Course. In case you are prepared, test your skills using TCS, Wipro, Amazon and Microsoft Test Serieses.