Daily Coding Challenges & Projects
Monday
Frontend Mini Project Challenge
JavaScript Logical Puzzle & Debugging
Challenge 1: JavaScript Logical Puzzle
Write a function flattenArray that flattens a nested array of arbitrary depth without using recursion.
Code:
// Input: [1, [2, [3, [4]], 5]]
// Output: [1, 2, 3, 4, 5]
Hint: Use a stack or a queue to iteratively flatten the array.
Challenge 2: JavaScript Debugging
Write a function flattenArray that flattens a nested array of arbitrary depth without using recursion.
Code:
let x = 10;
function check() {
if (x = 5) {
console.log("X is 5");
}
}
check();
Task : Find and fix the bug.
Backend Challenge
C, C++, C#
Challenge 1: C
Problem:
Write a function to reverse a linked list.
Challenge 2: C++
Problem:
Implement a thread-safe singleton class using C++11.
Challenge 3: C#
Problem:
Build a simple console app that reads a JSON file and displays its content using Newtonsoft.Json.
Database Query Challenge
Problems on SQL - HR Database :
- Write a SQL query to find employees who joined in the last 3 months.
- Write a SQL query to list employees whose salary is above the department average.
Data Structures & Algorithms Challenge
- Easy:
- Problem: Check if a given string is a palindrome.
- Hint: Use two-pointer technique.
- Medium:
- Problem: Implement LRU (Least Recently Used) Cache.
- Hint: Use a hash map and a doubly linked list.
- Hard:
- Problem: Solve the "Word Ladder" problem (Shortest path from beginWord to endWord using dictionary transformation).
- Hint: BFS + queue.
Bug of the Day
Language Focus :
C, C++, C#
Language: C
Buggy Code:
#include
int main() {
int arr[5] = {1, 2, 3};
for (int i = 0; i <= 5; i++) {
printf("%d ", arr[i]);
}
return 0;
}
Challenge : Find and fix the logical error.
📋 Daily Micro-Project
Frontend
Project:
Build a CSS-only animated loading spinner using @keyframes.
Trivia: 5 Fun Facts
- JavaScript was created in just 10 days by Brendan Eich in 1995.
- The C programming language was developed in 1972 at Bell Labs.
- Git was created by Linus Torvalds, the creator of Linux.
- The first computer programmer is considered to be Ada Lovelace.
- CSS stands for Cascading Style Sheets and was first proposed in 1994.
Tool of the Day (Updated)
Tool: CodePen
- CodePen Learn
- CodePen Collections
CodePen is a popular online code editor and social development environment for front-end designers and developers. It’s great for writing HTML, CSS, and JavaScript directly in the browser and seeing results instantly.
Resource Roundup:
Interview Question of the Day
Daily Interview Questions
- What is the difference between null and undefined in JavaScript?
- Explain how event delegation works in JavaScript.
- How does the virtual DOM work in React?
- What is the difference between v-if and v-show in Vue.js?
- What's the difference between a thread and a process?
- How does memory allocation work in C?
- What is the difference between stack and heap memory?
- Explain the use of pointers in C and why they matter.
- Explain normalization in SQL.
- What is a foreign key?
- What is the difference between clustered and non-clustered indexes?
- What is a kernel in an operating system?
- What is the difference between Docker and a virtual machine?
Daily Quiz Challenge
- What will typeof NaN return?
- "number"
- "NaN"
- "undefined"
- "object"
- What does document.querySelectorAll(".item") return?
- Node
- Array
- NodeList
- HTMLCollection
- Which CSS property is used to control stacking order?
- float
- z-index
- stack-order
- position
Frontend :
- Which operator is used to access members of a structure in C?
- .
- ->
- ::
- both a and b
- In C++, what is RAII?
- A type of loop
- Memory leak pattern
- Resource Acquisition Is Initialization
- Class inheritance
- In C#, what keyword is used to make a method asynchronous?
- await
- async
- defer
- thread
Backend :
- What SQL keyword is used to sort result sets?
- ORDER
- SORT
- ORDER BY
- GROUP BY
Database :
- What command is used to list files in a Linux directory?
- ls
- cd
- list
- mv
Other Tech :
- Which language uses indentation as syntax?
- JavaScript
- Python
- C++
- Java
Mixed Quiz :
Weekly Cross-Domain Activities ( Updated ) ( May 02 to May 08, 2025 )
API of the Day:
Challenge : Cat Facts API
Build a fun web app that displays random cat facts. Add a "New Fact" button to fetch and display a new fact with each click.
API: https://catfact.ninja/fact
Linux/DevOps Tip:
Automate Backups with cron
Use crontab -e to schedule a daily backup of a directory:
0 2 * * * tar -czf /backup/$(date +\%F).tar.gz /your/data/folder
This runs at 2:00 AM daily and compresses your target folder into a date-stamped .tar.gz archive.
Real-World Project of the Week ( Updated ) ( May 02 to May 08, 2025 )
Project of the Week:
- Users should be able to create blog posts using Markdown files. Convert them to HTML for rendering.
Build a Markdown Blog Engine using Node.js + Express or Flask.
Collaborative Project:
Contribute to Public APIs GitHub repo — help by submitting useful APIs or improving documentation for developers worldwide.
Case Study:
Study "Trello" clone functionality
Focus on drag-and-drop lists, card management, and task labels using React + Redux or Vue + Pinia.
Previous Daily Coding Challenges & Projects : 04-04-2025 07-04-2025 08-04-2025 09-04-2025 10-04-2025 11-04-2025 14-04-2025 15-04-2025 16-04-2025 17-04-2025 18-04-2025 21-04-2025 22-04-2025 23-04-2025 24-04-2025 25-04-2025 28-04-2025 29-04-2025 30-04-2025 01-05-2025 02-05-2025