Coding Interview Resources
51.8K subscribers
784 photos
7 files
468 links
This channel contains the free resources and solution of coding problems which are usually asked in the interviews.

Managed by: @love_data
Download Telegram
DSA Handwritten Notes
โค9
Best practices for writing SQL queries:

1- Filter Early, Aggregate Late: Apply filtering conditions in the WHERE clause early in the query, and perform aggregations in the HAVING or SELECT clauses as needed.

2- Use table aliases with columns when you are joining multiple tables.

3- Never use select *, always mention list of columns in select clause before deploying the code.

4- Add useful comments wherever you write complex logic. Avoid too many comments.

5- Use joins instead of correlated subqueries when possible for better performance.

6- Create CTEs instead of multiple sub queries, it will make your query easy to read.

7- Join tables using JOIN keywords instead of writing join condition in where clause for better readability.

8- Never use order by in sub queries, It will unnecessary increase runtime. In fact some databases don't even allow you to do that.

9- If you know there are no duplicates in 2 tables, use UNION ALL instead of UNION for better performance.
โค2
๐—™๐—ฅ๐—˜๐—˜ ๐—ข๐—ป๐—น๐—ถ๐—ป๐—ฒ ๐— ๐—ฎ๐˜€๐˜๐—ฒ๐—ฟ๐—ฐ๐—น๐—ฎ๐˜€๐˜€ ๐—ข๐—ป ๐—•๐˜† ๐—œ๐—ป๐—ฑ๐˜‚๐˜€๐˜๐—ฟ๐˜† ๐—˜๐˜…๐—ฝ๐—ฒ๐—ฟ๐˜๐˜€ ๐Ÿ˜

Choose the Right Career Path in 2026

Learn โ†’ Level Up โ†’ Get Hired

๐ŸŽฏ Join this FREE Career Guidance Session & find:
โœ” The right tech career for YOU
โœ” Skills companies are hiring for
โœ” Step-by-step roadmap to get a job

๐Ÿ‘‡ ๐—ฆ๐—ฎ๐˜ƒ๐—ฒ ๐˜†๐—ผ๐˜‚๐—ฟ ๐˜€๐—ฝ๐—ผ๐˜ ๐—ป๐—ผ๐˜„ (๐—Ÿ๐—ถ๐—บ๐—ถ๐˜๐—ฒ๐—ฑ ๐˜€๐—ฒ๐—ฎ๐˜๐˜€)

https://pdlink.in/4sNAyhW

Date & Time :- 18th March 2026 , 7:00 PM
SQL Interview Questions for 0-1 year of Experience (Asked in Top Product-Based Companies).

Sharpen your SQL skills with these real interview questions!

Q1. Customer Purchase Patterns -
You have two tables, Customers and Purchases: CREATE TABLE Customers ( customer_id INT PRIMARY KEY, customer_name VARCHAR(255) ); CREATE TABLE Purchases ( purchase_id INT PRIMARY KEY, customer_id INT, product_id INT, purchase_date DATE );
Assume necessary INSERT statements are already executed.
Write an SQL query to find the names of customers who have purchased more than 5 different products within the last month. Order the result by customer_name.

Q2. Call Log Analysis -
Suppose you have a CallLogs table: CREATE TABLE CallLogs ( log_id INT PRIMARY KEY, caller_id INT, receiver_id INT, call_start_time TIMESTAMP, call_end_time TIMESTAMP );
Assume necessary INSERT statements are already executed.
Write a query to find the average call duration per user. Include only users who have made more than 10 calls in total. Order the result by average duration descending.

Q3. Employee Project Allocation - Consider two tables, Employees and Projects:
CREATE TABLE Employees ( employee_id INT PRIMARY KEY, employee_name VARCHAR(255), department VARCHAR(255) ); CREATE TABLE Projects ( project_id INT PRIMARY KEY, lead_employee_id INT, project_name VARCHAR(255), start_date DATE, end_date DATE );
Assume necessary INSERT statements are already executed.
The goal is to write an SQL query to find the names of employees who have led more than 3 projects in the last year. The result should be ordered by the number of projects led.
โค2๐Ÿ‘1
๐—™๐—ฟ๐—ฒ๐˜€๐—ต๐—ฒ๐—ฟ๐˜€ ๐—–๐—ฎ๐—ป ๐—š๐—ฒ๐˜ ๐—ฎ ๐Ÿฏ๐Ÿฌ ๐—Ÿ๐—ฃ๐—” ๐—๐—ผ๐—ฏ ๐—ข๐—ณ๐—ณ๐—ฒ๐—ฟ ๐˜„๐—ถ๐˜๐—ต ๐—”๐—œ & ๐——๐—ฆ ๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฐ๐—ฎ๐˜๐—ถ๐—ผ๐—ป๐Ÿ˜

IIT Roorkee offering AI & Data Science Certification Program

๐Ÿ’ซLearn from IIT ROORKEE Professors
โœ… Students & Fresher can apply
๐ŸŽ“ IIT Certification Program
๐Ÿ’ผ 5000+ Companies Placement Support

Deadline: 22nd March 2026

๐Ÿ“Œ ๐—ฅ๐—ฒ๐—ด๐—ถ๐˜€๐˜๐—ฒ๐—ฟ ๐—ก๐—ผ๐˜„ ๐Ÿ‘‡ :-

https://pdlink.in/4kucM7E

Big Opportunity, Do join asap!
โค1
โœ… Essential Programming Acronyms You Should Know ๐Ÿ’ป๐Ÿง 

API โ†’ Application Programming Interface
Set of rules allowing software apps to communicate and exchange data seamlessly.

IDE โ†’ Integrated Development Environment
Software suite combining tools like editor, debugger, and compiler for efficient coding.

OOP โ†’ Object-Oriented Programming
Paradigm organizing code around objects and classes for reusability and modularity.

HTML โ†’ HyperText Markup Language
Standard markup language for structuring web pages and content.

CSS โ†’ Cascading Style Sheets
Stylesheet language defining presentation and layout of HTML documents.

SQL โ†’ Structured Query Language
Language for managing and manipulating relational databases.

JSON โ†’ JavaScript Object Notation
Lightweight data-interchange format easy for humans and machines to parse.

DOM โ†’ Document Object Model
Tree-like representation of a web page's structure for dynamic manipulation.

CRUD โ†’ Create, Read, Update, Delete
Core database operations for managing data persistence.

SDK โ†’ Software Development Kit
Collection of tools, libraries, and docs for building on a platform.

UI โ†’ User Interface
Point of interaction between user and software application.

UX โ†’ User Experience
Overall feel of the interaction with a product or service.

CLI โ†’ Command Line Interface
Text-based interface for issuing commands to software.

HTTP โ†’ HyperText Transfer Protocol
Foundation protocol for data communication on the web.

REST โ†’ Representational State Transfer
Architectural style for designing scalable web APIs using standard HTTP methods.

๐Ÿ’ฌ Tap โค๏ธ for more!
โค3
๐Ÿ“ข ๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฐ๐—ฎ๐˜๐—ถ๐—ผ๐—ป ๐—”๐—น๐—ฒ๐—ฟ๐˜ โ€“ Data Analytics with Artificial Intelligence

Upgrade your career with AI-powered data science skills.
Open for all. No Coding Background Required

๐Ÿ“Š Learn Data Analytics with Artificial Intelligence from Scratch
๐Ÿค– AI Tools & Automation
๐Ÿ“ˆ Build real world Projects for job ready portfolio
๐ŸŽ“ E&ICT IIT Roorkee Certification Program

๐Ÿ”ฅDeadline :- 22nd March

๐—”๐—ฝ๐—ฝ๐—น๐˜† ๐—ก๐—ผ๐˜„ ๐Ÿ‘‡ :- 
https://pdlink.in/4tkErvS

Don't Miss This Opportunity. Get Placement Assistance With 5000+ Companies
โค2
๐ŸŽฏ ๐Ÿ’ป Coding Interview Questions (With Answers)

๐Ÿง  1๏ธโƒฃ Tell me about yourself
โœ… Sample Answer:
"I have 4+ years as a software engineer specializing in full-stack development and algorithms. I've built scalable systems handling 1M+ daily users at a fintech startup using MERN stack and microservices. Expert in JavaScript/Python, system design, and competitive programming (LeetCode 2000+/2800). I love writing clean, testable code and optimizing for performance under scale."

๐Ÿ“Š 2๏ธโƒฃ What is the difference between a stack and a queue?
โœ… Answer:
A stack follows LIFO (Last In, First Out) principle with operations push (add to top) and pop (remove from top). Use cases: function call stack, undo/redo features.
A queue follows FIFO (First In, First Out) with enqueue (add to rear) and dequeue (remove from front). Use cases: breadth-first search, task scheduling, printers.
Both O(1) operations with arrays/linked lists.

๐Ÿ”— 3๏ธโƒฃ What is the difference between time complexity and space complexity?
โœ… Answer:
Time complexity measures how runtime grows with input size n (e.g., O(nยฒ) quadratic loops).
Space complexity measures memory usage growth (e.g., O(n) array stores all elements).
Tradeoffs exist: recursion uses stack space O(n), iteration uses O(1). Always analyze both.

๐Ÿง  4๏ธโƒฃ How do you find duplicates in an array?
โœ… Answer:
Optimal: Hash Set O(n) time/space
function findDuplicates(arr) {
const seen = new Set();
const dups = new Set();
for (let num of arr) {
if (seen.has(num)) dups.add(num);
else seen.add(num);
}
return Array.from(dups);
}

Space optimized: Sort O(n log n) then scan adjacent equals.

๐Ÿ“ˆ 5๏ธโƒฃ What is binary search and when would you use it?
โœ… Answer:
Binary search finds target in sorted array in O(log n) by repeatedly dividing search interval in half:
mid = (left + right) / 2
If arr[mid] == target return mid
If arr[mid] < target search right half
Else search left half
Use when: Data naturally sorted or sorting cost acceptable. Iterative version avoids recursion stack overflow.

๐Ÿ“Š 6๏ธโƒฃ How do you reverse a linked list?
โœ… Answer:
Iterative O(n) solution flipping next pointers:
function reverseList(head) {
let prev = null, curr = head;
while (curr) {
let nextTemp = curr.next;
curr.next = prev;
prev = curr;
curr = nextTemp;
}
return prev;
}

Recursive: reverseList(curr.next).then(curr.next.prev = curr, curr.next = null).

๐Ÿ“‰ 7๏ธโƒฃ What is recursion and why is the base case important?
โœ… Answer:
Recursion is a function calling itself with modified arguments until base case stops it. Without base case โ†’ stack overflow.
Example Fibonacci:
function fib(n) {
if (n <= 1) return n; // Base case
return fib(n-1) + fib(n-2);
}

Memoization optimizes overlapping subproblems.

๐Ÿ“Š 8๏ธโƒฃ How do you merge two sorted arrays?
โœ… Answer:
Two-pointer technique O(n+m):
function mergeSorted(a1, a2) {
let i=0, j=0, result = [];
while (i < a1.length && j < a2.length) {
if (a1[i] < a2[j]) result.push(a1[i++]);
else result.push(a2[j++]);
}
return result.concat(a1.slice(i)).concat(a2.slice(j));
}

Handles unequal lengths cleanly.

๐Ÿง  9๏ธโƒฃ How do you detect a cycle in a linked list?
โœ… Answer:
Floyd's Tortoise & Hare: Slow moves 1 step, fast moves 2. If they meet โ†’ cycle.
To find start: Reset slow to head, move both 1 step until meet.
function hasCycle(head) {
let slow = head, fast = head;
while (fast && fast.next) {
slow = slow.next;
fast = fast.next.next;
if (slow === fast) return true;
}
return false;
}

Double Tap โค๏ธ For More
โค6
๐—ง๐—ผ๐—ฝ ๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฐ๐—ฎ๐˜๐—ถ๐—ผ๐—ป๐˜€ ๐—ง๐—ผ ๐—š๐—ฒ๐˜ ๐—›๐—ถ๐—ด๐—ต ๐—ฃ๐—ฎ๐˜†๐—ถ๐—ป๐—ด ๐—๐—ผ๐—ฏ ๐—œ๐—ป ๐Ÿฎ๐Ÿฌ๐Ÿฎ๐Ÿฒ๐Ÿ˜

๐ŸŒŸ 2000+ Students Placed
๐Ÿค 500+ Hiring Partners
๐Ÿ’ผ Avg. Rs. 7.4 LPA
๐Ÿš€ 41 LPA Highest Package

Fullstack :- https://pdlink.in/4hO7rWY

Data Analytics :- https://pdlink.in/4fdWxJB

๐Ÿ“ˆ Start learning today, build job-ready skills, and get placed in leading tech companies.
โค1
๐Ÿ”ฅ A-Z Backend Development Roadmap ๐Ÿ–ฅ๏ธ๐Ÿง 

1. Internet & HTTP Basics ๐ŸŒ
- How the web works (client-server model)
- HTTP methods (GET, POST, PUT, DELETE)
- Status codes
- RESTful principles

2. Programming Language (Pick One) ๐Ÿ’ป
- JavaScript (Node.js)
- Python (Flask/Django)
- Java (Spring Boot)
- PHP (Laravel)
- Ruby (Rails)

3. Package Managers ๐Ÿ“ฆ
- npm (Node.js)
- pip (Python)
- Maven/Gradle (Java)

4. Databases ๐Ÿ—„๏ธ
- SQL: PostgreSQL, MySQL
- NoSQL: MongoDB, Redis
- CRUD operations
- Joins, Indexing, Normalization

5. ORMs (Object Relational Mapping) ๐Ÿ”—
- Sequelize (Node.js)
- SQLAlchemy (Python)
- Hibernate (Java)
- Mongoose (MongoDB)

6. Authentication & Authorization ๐Ÿ”
- Session vs JWT
- OAuth 2.0
- Role-based access
- Passport.js / Firebase Auth / Auth0

7. APIs & Web Services ๐Ÿ“ก
- REST API design
- GraphQL basics
- API documentation (Swagger, Postman)

8. Server & Frameworks ๐Ÿš€
- Node.js with Express.js
- Django or Flask
- Spring Boot
- NestJS

9. File Handling & Uploads ๐Ÿ“
- File system basics
- Multer (Node.js), Django Media

10. Error Handling & Logging ๐Ÿž
- Try/catch, middleware errors
- Winston, Morgan (Node.js)
- Sentry, LogRocket

11. Testing & Debugging ๐Ÿงช
- Unit testing (Jest, Mocha, PyTest)
- Postman for API testing
- Debuggers

12. Real-Time Communication ๐Ÿ’ฌ
- WebSockets
- Socket.io (Node.js)
- Pub/Sub Models

13. Caching โšก
- Redis
- In-memory caching
- CDN basics

14. Queues & Background Jobs โณ
- RabbitMQ, Bull, Celery
- Asynchronous task handling

15. Security Best Practices ๐Ÿ›ก๏ธ
- Input validation
- Rate limiting
- HTTPS, CORS
- SQL injection prevention

16. CI/CD & DevOps Basics โš™๏ธ
- GitHub Actions, GitLab CI
- Docker basics
- Environment variables
- .env and config management

17. Cloud & Deployment โ˜๏ธ
- Vercel, Render, Railway
- AWS (EC2, S3, RDS)
- Heroku, DigitalOcean

18. Documentation & Code Quality ๐Ÿ“
- Clean code practices
- Commenting & README.md
- Swagger/OpenAPI

19. Project Ideas ๐Ÿ’ก
- Blog backend
- RESTful API for a todo app
- Authentication system
- E-commerce backend
- File upload service
- Chat server

20. Interview Prep ๐Ÿง‘โ€๐Ÿ’ป
- System design basics
- DB schema design
- REST vs GraphQL
- Real-world scenarios

๐Ÿš€ Top Resources to Learn Backend Development ๐Ÿ“š
โ€ข MDN Web Docs
โ€ข Roadmap.sh
โ€ข FreeCodeCamp
โ€ข Backend Masters
โ€ข Traversy Media โ€“ YouTube
โ€ข CodeWithHarry โ€“ YouTube

๐Ÿ’ฌ Double Tap โ™ฅ๏ธ For More
โค6
๐——๐—ฎ๐˜๐—ฎ ๐—ฆ๐—ฐ๐—ถ๐—ฒ๐—ป๐—ฐ๐—ฒ ๐—™๐—ฅ๐—˜๐—˜ ๐—ข๐—ป๐—น๐—ถ๐—ป๐—ฒ ๐— ๐—ฎ๐˜€๐˜๐—ฒ๐—ฟ๐—ฐ๐—น๐—ฎ๐˜€๐˜€๐Ÿ˜

Kickstart Your Data Science Career In Top Tech Companies

๐Ÿ’ซLearn Tools, Skills & Mindset to Land your first Job
๐Ÿ’ซJoin this free Masterclass for an expert-led session on Data Science

Eligibility :- Students ,Freshers & Working Professionals

๐—ฅ๐—ฒ๐—ด๐—ถ๐˜€๐˜๐—ฒ๐—ฟ ๐—™๐—ผ๐—ฟ ๐—™๐—ฅ๐—˜๐—˜๐Ÿ‘‡ :- 

https://pdlink.in/4dLRDo6

( Limited Slots ..Hurry Up๐Ÿƒโ€โ™‚๏ธ )

Date & Time :- 26th March 2026 , 7:00 PM
โค4
Complete roadmap to learn Python and Data Structures & Algorithms (DSA) in 2 months

### Week 1: Introduction to Python

Day 1-2: Basics of Python
- Python setup (installation and IDE setup)
- Basic syntax, variables, and data types
- Operators and expressions

Day 3-4: Control Structures
- Conditional statements (if, elif, else)
- Loops (for, while)

Day 5-6: Functions and Modules
- Function definitions, parameters, and return values
- Built-in functions and importing modules

Day 7: Practice Day
- Solve basic problems on platforms like HackerRank or LeetCode

### Week 2: Advanced Python Concepts

Day 8-9: Data Structures in Python
- Lists, tuples, sets, and dictionaries
- List comprehensions and generator expressions

Day 10-11: Strings and File I/O
- String manipulation and methods
- Reading from and writing to files

Day 12-13: Object-Oriented Programming (OOP)
- Classes and objects
- Inheritance, polymorphism, encapsulation

Day 14: Practice Day
- Solve intermediate problems on coding platforms

### Week 3: Introduction to Data Structures

Day 15-16: Arrays and Linked Lists
- Understanding arrays and their operations
- Singly and doubly linked lists

Day 17-18: Stacks and Queues
- Implementation and applications of stacks
- Implementation and applications of queues

Day 19-20: Recursion
- Basics of recursion and solving problems using recursion
- Recursive vs iterative solutions

Day 21: Practice Day
- Solve problems related to arrays, linked lists, stacks, and queues

### Week 4: Fundamental Algorithms

Day 22-23: Sorting Algorithms
- Bubble sort, selection sort, insertion sort
- Merge sort and quicksort

Day 24-25: Searching Algorithms
- Linear search and binary search
- Applications and complexity analysis

Day 26-27: Hashing
- Hash tables and hash functions
- Collision resolution techniques

Day 28: Practice Day
- Solve problems on sorting, searching, and hashing

### Week 5: Advanced Data Structures

Day 29-30: Trees
- Binary trees, binary search trees (BST)
- Tree traversals (in-order, pre-order, post-order)

Day 31-32: Heaps and Priority Queues
- Understanding heaps (min-heap, max-heap)
- Implementing priority queues using heaps

Day 33-34: Graphs
- Representation of graphs (adjacency matrix, adjacency list)
- Depth-first search (DFS) and breadth-first search (BFS)

Day 35: Practice Day
- Solve problems on trees, heaps, and graphs

### Week 6: Advanced Algorithms

Day 36-37: Dynamic Programming
- Introduction to dynamic programming
- Solving common DP problems (e.g., Fibonacci, knapsack)

Day 38-39: Greedy Algorithms
- Understanding greedy strategy
- Solving problems using greedy algorithms

Day 40-41: Graph Algorithms
- Dijkstraโ€™s algorithm for shortest path
- Kruskalโ€™s and Primโ€™s algorithms for minimum spanning tree

Day 42: Practice Day
- Solve problems on dynamic programming, greedy algorithms, and advanced graph algorithms

### Week 7: Problem Solving and Optimization

Day 43-44: Problem-Solving Techniques
- Backtracking, bit manipulation, and combinatorial problems

Day 45-46: Practice Competitive Programming
- Participate in contests on platforms like Codeforces or CodeChef

Day 47-48: Mock Interviews and Coding Challenges
- Simulate technical interviews
- Focus on time management and optimization

Day 49: Review and Revise
- Go through notes and previously solved problems
- Identify weak areas and work on them

### Week 8: Final Stretch and Project

Day 50-52: Build a Project
- Use your knowledge to build a substantial project in Python involving DSA concepts

Day 53-54: Code Review and Testing
- Refactor your project code
- Write tests for your project

Day 55-56: Final Practice
- Solve problems from previous contests or new challenging problems

Day 57-58: Documentation and Presentation
- Document your project and prepare a presentation or a detailed report

Day 59-60: Reflection and Future Plan
- Reflect on what you've learned
- Plan your next steps (advanced topics, more projects, etc.)

Best DSA RESOURCES: https://topmate.io/coding/886874

Credits: https://t.me/free4unow_backup

ENJOY LEARNING ๐Ÿ‘๐Ÿ‘
โค4
๐Ÿ“ข ๐—–๐—ฒ๐—ฟ๐˜๐—ถ๐—ณ๐—ถ๐—ฐ๐—ฎ๐˜๐—ถ๐—ผ๐—ป ๐—”๐—น๐—ฒ๐—ฟ๐˜ โ€“ ๐——๐—ฎ๐˜๐—ฎ ๐—”๐—ป๐—ฎ๐—น๐˜†๐˜๐—ถ๐—ฐ๐˜€ ๐˜„๐—ถ๐˜๐—ต ๐—”๐—œ

(No Coding Background Required)

Freshers are getting paid 10 - 15 Lakhs by learning Data Analytics WIth AI skill

๐Ÿ“Š Learn Data Analytics from Scratch
๐Ÿ’ซ AI Tools & Automation
๐Ÿ“ˆ Build real world Projects for job ready portfolio 
๐ŸŽ“ E&ICT IIT Roorkee Certification Program

๐Ÿ”ฅDeadline :- 29th March

 ๐—”๐—ฝ๐—ฝ๐—น๐˜† ๐—ก๐—ผ๐˜„๐Ÿ‘‡ :- 

https://pdlink.in/41f0Vlr

Don't Miss This Opportunity. Get Placement Assistance With 5000+ Companies
โค1