You are on page 1of 13

Cheat Sheet for Interview Preparations [Fresh Graduates]

[Note: * marked Topics/ Links are important]

Practise programming from these sites


1. *​https://leetcode.com/
2. https://www.hackerrank.com/
3. https://www.geeksforgeeks.org/

Let us C By Yeshwant Kanethkar

Youtube Channels

● *CS concepts -
https://www.youtube.com/channel/UCM-yUTYGmrNvKOCcAl21g3w/playlists
● *DS and Algorithms -
https://www.youtube.com/channel/UCZCFT11CWBi3MHNlGf019nw/playlists
● LeetCode - ​https://www.youtube.com/channel/UCCwqxvz193btM4QvJbVaw2Q/playlists
● LeetCode - ​https://www.youtube.com/channel/UCKvwPt6BifPP54yzH99ff1g
● LeetCode - ​https://www.youtube.com/channel/UCamg61pfZpRnTp5-L4XEM1Q
● MIT Open Courses - ​https://www.youtube.com/user/MIT/playlists
● CS concepts - ​https://www.youtube.com/channel/UCRPMAqdtSgd0Ipeef7iFsKw/playlists
● Coding - ​https://www.youtube.com/user/tusharroy2525/playlists

Aptitude/Reasoning

● Quantitative Aptitude 
1. *Numbers ( ​Learn​ | P
​ ractice​ ) 
2. *LCM and HCF ( L
​ earn​ | ​Practice LCM​ | P
​ ractice HCF​ ) 
3. *Work and Wages ( ​Learn​ | P
​ ractice​ ) 
4. Pipes and Cisterns ( L
​ earn​ | ​Practice​ ) 
5. *Time Speed Distance ( L
​ earn​ | P
​ ractice​ ) 
6. Trains, Boats and Streams ( L
​ earn​ | ​Practice​ ) 
7. *Percentages ( ​Learn​ | P
​ ractice​ ) 
8. *Ratio Proportion and Partnership ( ​Learn​ | P
​ ractice​ ) 
9. Mixtures and Alligation ( L
​ earn​ | ​Practice​ ) 
10. Algebra ( L
​ earn​ | ​Practice​ ) 
11. *Age ( ​Learn​ | P
​ ractice​ ) 
12. *Profit and Loss ( L
​ earn​ | ​Practice​ ) 
13. Simple Interest ( ​Learn​ | P
​ ractice​ ) 
14. Compound Interest ( L
​ earn​ | P
​ ractice​) 
15. *Mensuration 2D ( ​Learn​ | P
​ ractice​) 
16. Mensuration 3D ( L
​ earn​ | ​Practice​) 
17. Trigonometry & Height and Distances ( ​Learn​ | P
​ ractice​ ) 
18. *Progressions ( ​Learn​ | P
​ ractice​ ) 
19. *Logarithms ( ​Learn​ | Practice ) 
20. *Permutation and Combination ( ​Learn​ | P
​ ractice​ ) 
21. *Probability ( ​Learn​ | P
​ ractice​ ) 
22. Clocks ( ​Learn​ | P
​ ractice​ ) 
23. Calendars ( ​Learn​ | P
​ ractice​) 
24. Race ( ​Learn​ | P
​ ractice​ ) 
25. *Simplification and Approximation ( Learn | ​Practice​ ) 
● Data Interpretation ( L
​ earn​ | ​Practice​ ) 
● Reasoning (Logical Ability) 
1. *Series : Missing Numbers, Odd One Out ( ​Learn​ | P
​ ractice​ ) 
2. *Data Sufficiency ( ​Learn​ | P
​ ractice​ ) 
3. Assumptions and Conclusions, Courses of Action ( ​Learn​ | 
Practice​ ) 
4. *Puzzles ( L
​ earn​ | ​Practice​ ) 
5. Syllogism ( L
​ earn​ | ​Practice​ ) 
6. *Cubes(​Placement | Cubes​) 
● English (Verbal Ability) 
1. Passage/Sentence Rearrangement ( L
​ earn​ ) 
2. Error Detection and Correction ( ​Learn​ ) 
3. Fill in the Blanks ( L
​ earn​ ) 
4. Comprehension Passages ( L
​ earn​ )

Operating System

Introduction to OS 
● Services and Examples 
● *Types of OS 
○ Single Tasking 
○ Multiprogramming and Multitasking 
○ Multithreading 
■ Real-world examples 
■ Disadvantages 
■ Examples of Race Condition 
○ *Multiprocessing 
○ Multiuser 
● ***Thread V/S Process 
● User Threads V/S Kernel Threads 

  

Virtual Memory 

● *Introduction 
○ Concept discussion 
○ Performance Impact of Page Fault 
● *TLB, Demand Paging, Thrashing, Page Replacement Algorithm 

Memory Management 

● *Working behind the compilation and running of a program 


● *Address Binding 
○ Compile Time 
○ Load Time 
○ Run Time 
○ Problems of Runtime Binding 
○ Logical and Physical Address 
● Runtime Binding 
○ Working 
● Memory Management and hierarchy 
○ Access time, capacity and cost 
● *Evolution of Memory Management 
○ Single Tasking 
○ Multitasking 
○ Memory Allocation 
● *Dynamic Partitioning 
○ Bitmap 
○ Linked List 

Deadlock 

● *Introduction and Understanding 


○ Mutual Exclusion 
○ Hold and Wait 
○ No Preemption 
○ Circular Wait 
○ Resource Allocation Graph 
● *Deadlock Handling Mechanism 
○ Deadlock Prevention 
○ Deadlock Avoidance 
○ Detection and Recovery 
○ Ignoring the Deadlock 
○ EDEADLK 
● *Deadlock Prevention Mechanism 
○ Mutual Exclusion 
○ Hold and Wait 
○ No Preemption 
○ Circular Wait 
● *Deadlock Avoidance Mechanism 
○ Bankers Algorithm 
● *Discussion on Deadlock Detection and Recovery 

**Process Synchronization 

● Introduction 
● *Consumer and Producer Problem 
● **Race Condition 
● *Goals of Synchronization Mechanism 
○ Mutual Exclusion 
○ Progress 
○ Bounded Waiting 
○ Performance 
● *Overview of Synchronization Mechanism 
○ Disabling Interrupts 
○ Locks(or Mutex) 
○ Semaphores 
○ Monitors 
○ Application of Process Synchronization 
● Locks for Synchronization 
○ Problems of Deposit and Withdrawl problem 
○ TSL Lock mechanism 
● *Critical Section 
○ Problems of Deposit and Withdrawl problem 
○ Entry Section 
○ Critical Section  
○ Exit Section 
○ Non-Critical Section 
● *Semaphores 
○ wait() and signal() function 
○ Original importance by Dijkstra 
● *Binary Semaphore 
○ Internal Working of Semaphore 
○ Binary Semaphore 
○ Wait and Signal Protocol in Binary Semaphore 
● *Monitors 
○ Introduction, Syntax and Working 

**Process Management 

● *Introduction to Program and Process 


● Process States 
○ For Single Tasking Systems. 
○ Multiprogramming Systems  
○ 5-States Model 
○ 7-States Model 
● *Process Control Block(PCB) 
● Process Scheduler 
○ Long Term Scheduler 
○ Short Term Scheduler 
○ Medium Term Scheduler 
● **Scheduling Algorithms 
○ Background 
○ Explaining various times in Scheduling algorithms 
○ Goals of Scheduling Algorithms 
● **FCFS Algorithm (Non-Preemptive) 
○ Understanding using a problem 
○ Calculating various times 
○ Characteristics of FCFS Algo 
● **SJFS Algorithm (Non-Preemptive) 
○ Understanding using a problem 
○ Calculating various times 
○ Characteristics of SJFS Algo 
● **SJF or SRTF Algorithm(Pre-emptive) 
○ Understanding using a problem 
○ Calculating various times 
○ Characteristics of SJF or SRTF Algo 
● *Priority Scheduling (Non-Preemptive) 
○ Understanding using a problem 
○ Calculating various times 
● *Priority Scheduling (Preemptive) 
○ Understanding using a problem 
○ Calculating various times 
● *Problems with Priority Scheduling 
● *Round Robin Scheduling (Pre-emptive) 
○ Characteristic 
○ Calculating various times using a problem 
● Multilevel Queue Scheduling 
● Multilevel Queue Scheduling with Feedback 

Database System

● *Introduction to DBMS 
○ Understanding DBMS 
○ Evolution of DBMS 
■ File-Based 
■ Relational DBMS 
■ NoSQL 
● **ER and Relational Model 
○ ER Model 
■ Understanding Entity Set, Relationship Set and Attributes. 
○ Keys 
■ Candidate Key 
■ Super Key 
■ Primary Key 
■ Problems involving identifying keys. 
○ ER Diagram 
■ Participation  
■ Weak Entity Set 
○ Foreign Key 
■ Introduction and Identifying foreign keys 
■ Understanding Referential Integrity 
● ***Database Designing 
https://www.ntu.edu.sg/home/ehchua/programming/sql/Relational_Database_Design.ht
ml 

https://www.guru99.com/database-design.html 

○ Normalization 
■ Data Redundancy 
■ Data Integrity 
■ Objects of Good DB design 
■ Understanding Anomalies 
■ Updation Anomaly 
■ Insertion Anomaly 
■ Deletion Anomaly 
○ Functional Dependency 
■ Explanation using DB tables 
■ Need for Functional Dependency 
■ Trivial and Non-trivial 
○ First Normal Form 
○ Second Normal Form 
○ Third Normal Form 
○ BCNF 
● **SQL 
○ Introduction 
■ DDL, DQL, DML, DCL 
■ Understanding the creation of tables using SQL commands 
■ INSERT, SELECT, FROM 
○ Joins in SQL 
■ Cross Product 
■ Inner Join - Equal and Natural Join 
■ Outer Join - Left, Right and Full Join 
■ Self Join 
○ Aggregate Functions and Group By 
■ SUM, MAX, MIN, COUNT, AVG 
■ Group BY 
■ Difference b/w WHERE & HAVING 
○ Subqueries 
■ Understanding querying from the table using SQL commands 
■ Various problems in subqueries 
○ Correlated subqueries 
● *Indexing 
○ Indexing in Database 
■ Introduction to Clustered and Non clustered indexing 
○ Clustered Index 
■ Sparse and Dense Index 
○ Non-clustered Index 
○ Multilevel Indexing B & B+ Trees 
● Transaction and Concurrency Control 
○ Introduction and ACID properties 
○ Conflict Serializability 
■ Conflicting operators in Transactions 
■ Given and Serial Schedule 
■ Precedence Graph 
○ View Serializability 
■ Initial Read 
■ Updated Read 
■ Final Write 
○ Recoverable, Cascadeless and Strict Schedule 
○ Two-Phase Locking Protocol 
■ Understanding Shared and Exclusive Locks 
■ Growing and Shrinking phase 
○ Problems with basic two-phase locking 
■ Deadlock 
■ Recoverability 
○ Conservative, Strict and Rigorous 2PL 
■ Difference between them 
○ Timestamp Based Protocols 
■ Rules to find: 
■ TS 
■ RTS 
■ WTS 

Computer Networks
**​https://www.journaldev.com/35984/osi-model
https://www.studytonight.com/computer-networks/overview-of-computer-networks
● **Introduction to CN 
○ Network Criteria Discussion 
○ OSI Model 
■ The need for such a model 
■ Various layers at Sender and Receiver side 
○ TCP/IP Model 
■ The need for such a model 
■ Various layers at Sender and Receiver side 
■ Protocol Data Units 
● **Data Link Layer 
○ Introduction 
■ Explanation using Home and Office network 
■ Functionalities 
■ Framing 
■ Error Detection 
■ Error Flow Control 
■ Multiple Access 
○ Delays 
■ Transmission Delay 
■ Propagation Delay 
■ Queuing Delay 
■ Processing Delay 
○ Error and Flow Control Protocols 
■ Stop and Wait 
■ Selective Repeat Protocol 
■ Sliding Window Background 
■ Go Back N 
○ Circuit Switching V/S Packet Switching 
■ Difference and explanation 
● *Network Layer 
○ Introduction 
■ Functionalities 
○ Network Address Translation 
■ Identifying private and public IPs 
○ Routing Algorithms 
■ Exterior Gateway Protocols 
■ Interior Gateway Protocols 
■ Static V/S Dynamic Routing Algorithms 
■ Unicast, Broadcast, Multicast & Anycast 
■ Cost of Links 
■ Goals of Routing Algos 
○ Distance Vector Routing 
■ Introduction 
■ Algorithm 
■ Problems 
■ Routing Information Protocols 
○ Link State Routing 
■ Introduction 
■ Algorithm 
■ Use 
● *Transport Layer 
○ Introduction 
■ Use and Examples 
○ TCP V/S UDP 
■ Difference and explanation 
● *Application Layer 
○ Introduction 
■ Working of various layers 
○ Understanding and background of Domain Name System 
○ Address Resolution Protocol (ARP) 
■ Working 
○ Dynamic Host Configuration Protocol (DHCP) 
■ Working at Home and Office Network 
● *IP Addressing 
○ Classful Addressing 
■ Problems 
○ Subnetting 
■ Subnet Mask 
■ The division into two or more networks 
■ Problems 
○ Classless Addressing 
■ Classless Inter-Domain Routing 
■ Problem with classful addressing 

  

Data Structures​**
● Arrays
● Map (HashMap)

Problem:

Given an array of strings, group anagrams together.

Example:

Input: ["eat", "tea", "tan", "ate", "nat", "bat"],

Output:
[
["ate","eat","tea"], 1
["nat","tan"], 2
["bat"] 3
]

class Solution {
public List<List<String>> groupAnagrams(String[] strs) {
Map<String, List<String>> map = new HashMap<>();
for (String str: strs) {
char[] chs = str.toCharArray();
Arrays.sort(chs);
String key = new String(chs);
List<String> list;
if (map.containsKey(key)) {
list = map.get(key);
list.add(str);
} else {
list = new ArrayList<>();
list.add(str);
}
map.put(key, list);
}
List<List<String>> result = new ArrayList<>();
for (String key: map.keySet()) {
result.add(map.get(key));
}
return result;
}
}

● Linked List (nth node from end, loop in a linked list, reverse a linked list, circular linked
list, doubly linked list)
● Stacks
● Queues
● Trees (Binary Tree, Traversal (in- order, pre-order, post-order, level order, BST)
● Trie (String prefix/suffix based problem)
● Dynamic Programming
● Graph (Traversal, standard algorithms, topological sort)
● Searching and Sorting (Binary Search)
● Hashing
● Bit manipulation

*Top questions for practise -


https://www.geeksforgeeks.org/top-10-algorithms-in-interview-questions/

*Frequently asked coding problems ​https://leetcode.com/problemset/top-100-liked-questions/

* Solution to LeetCode - ​https://github.com/Akcps/leetcode-solutions


Important Links

● *Introduction to Web -
https://www.studytonight.com/servlet/introduction-to-web.php
● *Introduction to Web Development -
https://careerfoundry.com/en/tutorials/web-development-for-beginners/introductio
n-to-web-development/​ ,
https://developer.mozilla.org/en-US/docs/Web/Guide/Introduction_to_Web_devel
opment
● *Core Java - ​https://qr.ae/pNyaKQ​ (Topics to cover for fresh graduates)
● *List of Important questions related to Core Java -
https://javasearch.buggybread.com/InterviewQuestions/questionSearch.php?sear
chOption=label&keyword=basic
● Sevlets - ​https://www.edureka.co/blog/java-servlets
● JSP - ​https://www.javatpoint.com/jsp-tutorial
● JDBC - ​https://www.javatpoint.com/java-jdbc
● *What happens when you you type a URL in the browser and press enter -
https://medium.com/@maneesha.wijesinghe1/what-happens-when-you-type-an-u
rl-in-the-browser-and-press-enter-bb0aa2449c1a

You might also like