30 Days JavaScript Challenge: Day 23 ✅ Today’s problem was about building our own version of groupBy() something that’s actually super useful in real projects. The idea was simple: Take an array, run a function on each element, and group elements based on the key that function returns. What I liked about this one is how it makes you think about data transformation not just looping, but structuring data in a cleaner and more usable way. Something like: Group users by id Split numbers based on a condition Organize data for UI rendering All of this becomes much easier once you understand this pattern. Another small step, but feels like I’m getting better at writing cleaner and more practical JavaScript. #javascript #leetcode #webdevelopment #frontenddeveloper #codingchallenge #learninginpublic #developers #programming #buildinpublic
Building Custom GroupBy Function in JavaScript
More Relevant Posts
-
30 Days JavaScript Challenge : Day 27 ✅ Today’s problem was about creating a compact object basically removing all falsy values from an object or array, even if they are nested. At first glance it looks easy, but once nested structures come in, it gets interesting. This problem really tests your understanding of: Falsy values (null, 0, false, "", etc.) Recursion for nested objects/arrays Treating arrays like objects (since indices are keys) It’s one of those questions that feels very practical like cleaning API responses or filtering unwanted data before using it. Definitely helped me think more deeply about how JavaScript handles data structures. Almost at the end now… consistency paying off 🚀 #javascript #leetcode #webdevelopment #frontenddeveloper #codingchallenge #learninginpublic #developers #programming #buildinpublic
To view or add a comment, sign in
-
-
30 Days JavaScript Challenge : Day 26 ✅ Today’s problem was about flattening a multi-dimensional array, but with a twist we were given a depth n and had to flatten only up to that level. Not a full flatten, not a shallow one… somewhere in between. It really makes you think about recursion and depth control: When to go deeper When to stop How to keep track of current depth What I liked is how this problem builds intuition around nested data structures something you see a lot in real apps (APIs, configs, UI trees, etc.). Slowly getting more comfortable with recursion and thinking in layers. #javascript #leetcode #webdevelopment #frontenddeveloper #codingchallenge #learninginpublic #developers #programming #buildinpublic
To view or add a comment, sign in
-
-
30 Days JavaScript Challenge : Day 24 ✅ Today’s problem was about sorting an array using a custom function. Instead of directly sorting values, we use a function fn to decide the order — basically telling JavaScript how to compare elements. At first it feels simple, but it actually shows how powerful sorting can be when you control the logic: Sorting objects based on a property Sorting nested arrays Custom ranking based on conditions It’s one of those concepts that looks basic but is used everywhere in real projects. Slowly getting more clarity on how to write flexible and reusable logic in JavaScript. #javascript #leetcode #webdevelopment #frontenddeveloper #codingchallenge #learninginpublic #developers #programming #buildinpublic
To view or add a comment, sign in
-
-
💡 JavaScript Challenge function sum(a, b) { return a + b; } function sumCurried(a) { return function(b) { return a + b; }; } console.log(sum(5, 4)); console.log(sumCurried(5)(4)); ❓ What’s the output? Two different approaches… one result. But here’s the real question 👇 Are you more curious about the answer… or how both paths lead there? 👇 Drop your answer below! 🔗 Follow me for more insights on coding, creativity & branding. #JavaScript #WebDevelopment #CodingChallenge #Curiosity #Programming #Developers #LearnToCode
To view or add a comment, sign in
-
-
📚 JavaScript: Array vs Object 💡 Many beginners get confused between Array and Object in JavaScript. But the difference is actually very simple 👇 ✅ Array • Used to store a list of items • Values are ordered • Access items by index like 0, 1, 2 Example: ["Apple", "Mango", "Banana"] ✅ Object • Used to store key-value pairs • Best for structured data • Access values by key Example: { name: "John", age: 25 } 👉 Use Array when you need a list. 👉 Use Object when you need data with labels. Understanding this basic concept makes JavaScript much easier to learn 🚀 #JavaScript #WebDevelopment #Programming #FrontendDevelopment #Coding #ReactJS #LearnJavaScript #Developer #TechCommunity #100DaysOfCode
To view or add a comment, sign in
-
-
🚀 Mastering JavaScript Fundamentals Understanding core concepts like Array & String methods is a game-changer for writing clean, efficient code. From map() and filter() to split() and trim(), these built-in methods help you solve problems faster and write smarter logic. 💡 Consistency in learning the basics builds a strong foundation for advanced development. Sharing this quick visual guide to help beginners and refresh concepts for developers! What’s your most used JavaScript method? 👇 #JavaScript #WebDevelopment #Coding #LearnToCode #Frontend #Programming #Developers
To view or add a comment, sign in
-
-
I wrote a blog on callbacks breaking down from first principles: • What a callback actually is • Why callbacks exist in async programming • How functions are passed as values • Where callbacks show up in real-world code • Why callback nesting becomes a problem If you’re learning JavaScript, this is one of those concepts that clears up a lot of confusion around async behavior 👇 https://lnkd.in/gvy6SSuw #JavaScript #WebDevelopment #AsyncJavaScript #Coding #LearnToCode #FrontendDevelopment #Programming #Developers #TechLearning #100DaysOfCode
To view or add a comment, sign in
-
📒 Just documented JavaScript Data Types in a clean handwritten format! Concepts feel much easier when you write and visualize them instead of just reading 📖✍️ Covered: ✔️ Primitive Types ✔️ Reference Types ✔️ Special Concepts like "typeof" & Dynamic Typing JavaScript is simple… but its behavior makes it powerful (and sometimes tricky 😄) Consistency in learning > speed 🚀 If you're learning JavaScript, start from the basics — they matter more than you think. 💬 What topic should I cover next? #JavaScript #WebDevelopment #CodingJourney #LearnToCode #Frontend #Programming #Developers #100DaysOfCode #Tech #CodeNewbie
To view or add a comment, sign in
-
-
🔥 JavaScript is evolving fast Some recent features are making code cleaner and easier 👇 Instead of writing complex logic, we now have: • Cleaner Set operations (union, intersection) • Immutable array methods (no accidental mutations) • Direct JSON imports (no need for fetch) Small changes… but they improve code readability and reduce bugs 🚀 I’m excited about writing cleaner and more predictable code with these improvements. JavaScript keeps getting better for developers 👩💻✨ Which feature are you most excited to try? #JavaScript #WebDevelopment #FrontendDeveloper #Programming #Tech
To view or add a comment, sign in
-
-
Maps and Sets in JavaScript: A Beginner-Friendly Guide JavaScript provides many ways to store and manage data. While Arrays and Objects are widely used, Maps and Sets are two powerful yet often overlooked data structures.... Read more → https://lnkd.in/dwk3yBJn #TheCampusCoders #Tech #Developers #Programming #WebDev
To view or add a comment, sign in
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development