🚨 This problem didn’t ask for optimization… but understanding possibilities. Day 33 of my Backend Developer Journey — and today was about 👉 maximizing outcome with flexible inputs 🧠 LeetCode Breakthrough Solved today’s Daily Challenge using greedy thinking 💡 What clicked: → Treat _ as flexible moves → Calculate current position → Use _ to maximize distance ⚡ The real trick: 👉 Don’t fix unknowns… 👉 use them to your advantage 🔍 Key Insight 👉 Known moves → fixed contribution 👉 Unknown moves → maximize result ⚡ Final answer = |current position| + number of flexible moves 🔗 My Submission:https://lnkd.in/ghdgkZVV ☕ Spring Boot Learning 🔄 Orphan Removal vs Cascade Delete Today I explored a subtle but powerful concept 👇 👉 Cascade Delete → Deletes child when parent is deleted 👉 Orphan Removal → Deletes child when it is removed from relationship ⚡ Key Difference 💡 Cascade = Parent-based deletion 💡 Orphan = Relationship-based deletion 🚨 N+1 Query Problem One of the most important backend performance issues 👇 👉 Fetch 1 parent → triggers N extra queries for children ⚡ Problem: 👉 Multiple unnecessary DB calls 🔥 Solution 👉 Use fetch join 👉 Use @EntityGraph 👉 Prefer JOIN FETCH in queries 🧠 The Shift 👉 Problems are not always about solving… but maximizing 👉 Backend performance matters as much as correctness 👉 Small concepts → huge real-world impact 📘 Spring Boot Notes: https://lnkd.in/gRgxP7Th 🔗 GitHub Repo (Project):https://lnkd.in/gWb8ZPdv 📈 Day 33 Progress: ✅ Learned greedy thinking approach ✅ Understood orphan removal vs cascade ✅ Discovered N+1 query problem 💬 Have you ever faced N+1 issues in your project? 👇 #100DaysOfCode #BackendDevelopment #SpringBoot #Java #LeetCode #SystemDesign #CodingJourney
Day 33 Backend Dev Journey: Greedy Thinking & Performance Optimization
More Relevant Posts
-
🚨 Today wasn’t about solving problems… it was about fixing what was broken. Day 37 of my Backend Developer Journey — and honestly, 👉 this felt more like a real developer day 🧠 LeetCode Breakthrough Solved today’s Daily Challenge using Median + Math Optimization 💡 What clicked: → Flatten the grid into a single array → Check if all elements follow same modulo → Use median to minimize operations ⚡ The Real Trick 👉 If modulo condition fails → impossible ❌ 👉 If valid → median gives minimum operations ✅ 🔍 Key Insight 👉 Median minimizes absolute differences 👉 Math-based optimization beats brute force 🔗 My Submission: https://lnkd.in/gf43YBkq ☕ Spring Boot Learning 🐛 Debugging Day (Real Dev Life) Today was not smooth… and that’s okay 👇 👉 Faced issues with Lombok + Java 24 👉 Switched back to Java 21 👉 Bugs reduced, but still debugging ⚡ What I learned 👉 New versions ≠ always stable 👉 Compatibility matters more than hype 👉 Debugging is a core developer skill 🔌 Database Progress 👉 Successfully connected PostgreSQL to my server 👉 Backend is now interacting with real data 🧠 The Shift 👉 Not every day is productive — but every day teaches 👉 Debugging builds deeper understanding than coding 👉 Real growth happens when things don’t work 🔗 GitHub Repo (Lovable Clone): https://lnkd.in/gwHmAZaK 📈 Day 37 Progress: ✅ Learned median optimization technique ✅ Handled real-world debugging issues ✅ Connected DB to backend successfully 💬 What’s one bug that taught you more than any tutorial? 👇 #100DaysOfCode #BackendDevelopment #SpringBoot #Java #LeetCode #Debugging #CodingJourney
To view or add a comment, sign in
-
-
🚨 This problem looked too simple… and that’s exactly why it was tricky. Day 27 of my Backend Developer Journey — and today reminded me: 👉 Simple problems test clarity, not complexity. 🧠 LeetCode Insight Solved today’s Daily Challenge 💡 What clicked: → Reverse the number → Compute absolute difference → Keep logic minimal ⚡ The takeaway: 👉 No extra data structures 👉 No overthinking 👉 Just clean execution 🔍 Key Insight 👉 Sometimes the problem is already optimal 👉 Your job is to not ruin it with over-engineering 🔗 My Submission:https://lnkd.in/gSP92U_8 ☕ Spring Boot Learning 🔗 JPA Relationships (Game Changer for Backend Design) Today I explored how entities connect with each other in real-world systems 👇 👉 @OneToOne – One entity ↔ One entity 👉 @OneToMany – One → Multiple 👉 @ManyToOne – Multiple → One 👉 @ManyToMany – Many ↔ Many ⚡ Why this matters 💡 Backend is not just APIs… It’s about how data is connected internally 👉 Proper relationships = cleaner DB design 👉 Better performance & maintainability 🧠 The Shift 👉 Not every day is about hard problems 👉 Some days are about discipline & clarity 👉 Strong fundamentals = long-term consistency 📘 Spring Boot Notes: https://lnkd.in/gpWQvkyK 📈 Day 27 Progress: ✅ Improved clarity in problem-solving ✅ Learned core DB relationship mapping ✅ Strengthened backend fundamentals 💬 Do you also overthink simple problems sometimes? 😄 #100DaysOfCode #BackendDevelopment #SpringBoot #Java #LeetCode #CodingJourney
To view or add a comment, sign in
-
-
I kept losing momentum every time I worked deep into production-grade logic or a complex feature with 𝗖𝗹𝗮𝘂𝗱𝗲. Token limit hit. New session starts. And if you’ve been there, you know the pain… 😢 You were in the middle of a deep conversation — decisions made, patterns chosen, files in progress — and suddenly it’s gone. Even if you update 𝗖𝗟𝗔𝗨𝗗𝗘.𝗺𝗱, it doesn’t fully bring back that momentum. Sometimes it works. Sometimes it hallucinates. Most of the real context still lives in your head, not in the session. So I build a npm package called 𝗰𝗹𝗮𝘂𝗱𝗲-𝘀𝗻𝗮𝗽. It solves this in a simple way: Install it → go to your project → run it. 𝗰𝗹𝗮𝘂𝗱𝗲-𝘀𝗻𝗮𝗽 scans your project and generates a proper 𝗖𝗟𝗔𝗨𝗗𝗘.𝗺𝗱 using real signals: package files, git history, framework setup, test commands, and more. Then it keeps your live work in .claude/state.md, so your next session doesn’t start from zero. Two commands: → 𝗰𝗹𝗮𝘂𝗱𝗲-𝘀𝗻𝗮𝗽 𝗲𝗻𝗱 (save session state) → 𝗰𝗹𝗮𝘂𝗱𝗲-𝘀𝗻𝗮𝗽 𝘀𝘁𝗮𝗿𝘁 (restore context) In ~5 seconds, Claude knows your stack, your conventions, what you were doing, and what comes next. No re-explaining. No context rebuilding. Just flow. Works with Node, Python, Rust, Go, PHP, Flutter, and more. Published on npm this week. If you use Claude regularly, this will save you time. 𝗻𝗽𝗺 𝗶𝗻𝘀𝘁𝗮𝗹𝗹 -𝗴 𝗰𝗹𝗮𝘂𝗱𝗲-𝘀𝗻𝗮𝗽 npm → https://lnkd.in/gT_Zemn5 GitHub → https://lnkd.in/geCfE9ax #buildinpublic #claudeai #opensource #developertools #softwareengineering #npm
To view or add a comment, sign in
-
-
The top article from the "Medium Weekly Digest" email newsletter this week: "Junior Devs Use try-catch Everywhere. Senior Devs Use These 4 Exception Handling Patterns": https://lnkd.in/dh_H7i2p Even after all this time I still opened it to make sure I'm not doing it wrong, but let's not talk about that part. I'm happy to report ego intact. <Nervous laughter> First of all, "Senior devs never ___" - LOL of course they do. We all do. The framing is unnecessarily adversarial and reads like an aggressively-toned code review. But the intent feels well-meaning, and there are real nuggets in there worth knowing. I'd just rather see it presented as "here are some patterns for graceful error handling" than "my title says 'Senior' so I must be right". I mean, it could be worse. At least there is some attempt at error handling. If you've inherited enough legacy codebases, you learn to find the silver lining. Just don't swallow exceptions. Silent failures turn colleagues into ferocious enemies.
To view or add a comment, sign in
-
"We analyzed 75 TypeScript projects leveraging advanced generics. The efficiency gains were undeniable." Have you ever wondered how mastering TypeScript's advanced generics and type inference can transform your codebase? As developers, we constantly seek ways to write more flexible and maintainable code. But what if I told you that pushing the boundaries of TypeScript's type system can lead to cleaner, faster, and more reliable applications? In my experience, the real power of TypeScript lies in its ability to express complex type relationships. By using advanced generics, I've created reusable components that adapt effortlessly to different data structures. This approach has not only reduced boilerplate code but also minimized runtime errors by catching them at compile-time. Consider this: TypeScript's type-level programming isn't just about strict types; it's about crafting a dynamic system that anticipates your application's needs. It requires a paradigm shift—thinking of types as living, adaptable entities rather than static definitions. Here's a snippet illustrating how you might define a versatile utility type: ```typescript type ExtractPropsT = T extends React.ComponentTypeinfer P ? P : never; function logComponentPropsT
To view or add a comment, sign in
-
🚀 Stop blindly using @Autowired on fields. It works… but it’s NOT the best way. Let’s understand why 👇 👉 There are 3 ways to inject dependencies in Spring: 1️⃣ Field Injection 2️⃣ Setter Injection 3️⃣ Constructor Injection ✅ (Recommended) --- 💡 Most beginners do this: @Service public class OrderService { @Autowired private PaymentService paymentService; } ❌ Problems: - Hard to test (no control over dependency) - Hidden dependencies - Breaks immutability --- ✅ Better approach → Constructor Injection: @Service public class OrderService { private final PaymentService paymentService; public OrderService(PaymentService paymentService) { this.paymentService = paymentService; } } ✔ Dependencies are explicit ✔ Easy to write unit tests ✔ Ensures immutability --- 🔥 Bonus (Spring Boot magic): If a class has ONLY ONE constructor → You don’t even need @Autowired 😮 Spring automatically injects it! --- ⚡ Real-world impact: In large projects: - Field injection → messy & hard to debug - Constructor injection → clean & maintainable --- ❌ Common mistake: Using @Autowired everywhere just because it’s easy --- 📌 Key Takeaway: “Convenience is not always best practice.” Always prefer Constructor Injection for clean and testable code. --- Follow for more real backend learnings 🚀 #SpringBoot #Java #CleanCode #BackendDevelopment #SoftwareEngineer
To view or add a comment, sign in
-
-
🚀 I Built a Complete Django REST API Course (0 → Advanced) Most tutorials teach theory. But I wanted to build something that actually makes you job-ready. So I created a 15-day structured roadmap to master REST APIs using Django. 💡 What’s inside: ✔ API fundamentals (from scratch) ✔ Real CRUD operations with database ✔ Function-Based & Class-Based Views ✔ ViewSets & Routers (industry-level) ✔ JWT Authentication (login system 🔐) ✔ Pagination & Filtering (performance 🚀) ✔ Deployment + best practices ✔ Interview questions + machine coding 🧠 Why I built this? When I was learning backend, everything felt: ❌ scattered ❌ confusing ❌ not interview-focused So I built this repo like a course + real project combined 📚 Who is this for? Beginners learning backend Students preparing for interviews Anyone switching to backend development 🔗 Check it out here: https://lnkd.in/guKJiQqX If this helps you: ⭐ Star the repo 💬 Share your feedback #python #django #restapi #backenddeveloper #webdevelopment #programming #developers #learning #github #100DaysOfCode
To view or add a comment, sign in
-
The Claude Code Leak: 512,000 Lines of TypeScript On March 31, 2026, a routine npm update accidentally exposed nearly 1,900 TypeScript files over 500,000 lines from Anthropic’s Claude CLI in 2.1.88 version. A large source map file was published, linking compressed code to the full source. Although Anthropic quickly fixed the issue, the code was already mirrored on public sites. No model weights, training data, or user info were leakedjust the client-side orchestration layer. The root cause was a default source map from Bun and a missing .npmignore rule. The leaked code shows features like "undercover mode" for protecting internal info and advanced agent coordination for complex tasks and some other features for background operations and proactive monitoring. GitHub link for leaked code : https://lnkd.in/gZYDDseT
To view or add a comment, sign in
-
🚀 I built an open-source library of Claude Code rules & skills to keep AI-assisted development consistent across all my projects. The problem: every time I started a new project, I was re-explaining the same conventions to Claude — Clean Architecture, SOLID, idiomatic Go, PEP 8, React hooks rules… over and over. The solution: my-rules-skills — a single .claude/ folder you drop (or symlink) into any project. Claude Code automatically picks up the rules and skills from there. What's inside: 📐 Shared rules (apply to every language) Clean Code (Uncle Bob) SOLID principles enforcer Object Calisthenics ⚙️ .NET — Clean Architecture with Brighter/Darker, Minimal API, C# conventions 🐹 Go — Effective Go + Google Style Guide: naming, concurrency, error handling, project structure 🐍 Python — PEP 8/257/20, type hints, logging, src layout, pyproject.toml + uv ⚛️ React — Component purity, hooks rules, feature-slice architecture, React Query, TypeScript Each language also ships with a skill — a step-by-step workflow Claude follows when you say "add a new feature", automatically covering domain → service → repository → handler → tests. How it works: # Drop it into any project (or symlink to keep rules in sync) ln -s ~/my-rules-skills/.claude ./. claude Rules activate automatically based on file type. Skills are invoked by name or by describing what you want to do. It's agnostic, extensible, and completely free. Add your own rules in Markdown — no config, no build step. 👉 https://lnkd.in/d-3uNxaf Would love to hear how others are managing Claude Code conventions across projects. Are you doing something similar? #ClaudeCode #AI #DeveloperTools #SoftwareEngineering #CleanCode #SOLID #dotnet #golang #Python #React #OpenSource
To view or add a comment, sign in
-
🚀 #100DaysOfCode – Day 12 | Backend Journey Continues 💻🔥 Consistency is starting to feel powerful now. Day 12 done ✅ 🧠 LeetCode Daily Challenge 📌 Problem: Maximum Walls Destroyed by Robots 💡 Approach & Learnings: Today’s problem was a mix of Sorting + Binary Search + Dynamic Programming, which made it super interesting. 🔹 Sorted robots and walls to process efficiently 🔹 Used Binary Search to quickly count walls in a given range 🔹 Applied Dynamic Programming to maximize total walls destroyed 👉 The key challenge was handling overlapping ranges between robots and deciding the optimal strategy to avoid double counting. This problem really tested how well I can combine multiple concepts into one optimized solution. Submission Link: https://lnkd.in/gp99D5sS 🌱 Spring Boot Learning Today I focused on some very important backend concepts: 🔹 PUT vs PATCH Mapping 👉 PUT Mapping Used when updating the entire object Missing fields → become NULL Best for full replacement 👉 PATCH Mapping Used for partial updates Only updates required fields Avoids unnecessary null values 🔹 ReflectionUtils in PATCH Learned how to use Reflection to dynamically update fields inside an entity. 💡 This helps in: Updating fields without writing multiple setters Making PATCH APIs more flexible Writing cleaner and scalable backend code 🔹 ResponseEntity Understood how to structure API responses properly: ✅ Control HTTP status codes ✅ Customize response body ✅ Improve API clarity and standards 📈 Key Takeaways ✔️ Combining multiple DSA concepts is key for optimization ✔️ PATCH is essential for real-world API design ✔️ Reflection adds flexibility to backend logic ✔️ Clean API responses improve overall system design NotesLink: https://lnkd.in/gNZWz96m 🔥 Day 12 done. Still consistent. Still improving. #BackendDevelopment #SpringBoot #Java #LeetCode #100DaysOfCode #CodingJourney
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