Day 7/30 of #30DaysOfCoding Implemented a palindrome checker for @iCodeThis Functional Challenge - pure logic, no UI fluff. Key Logic: Normalize input: `toLowerCase()` + strip non-alphanumerics, Compare string with its reverse via `split('').reverse().join('')` Learnings: Clean string manipulation is foundational for data validation and algorithms. 🛠 Vanilla JavaScript Feedback on regex optimization welcome! #30DaysOfCode #JavaScript #Algorithms #iCodeThis #FrontendDev
Palindrome checker implemented for iCodeThis challenge using JavaScript
More Relevant Posts
-
🔍 Day 171 of #200DaysOfCode Today, I implemented a function to check whether a specific value exists in an array — without using built-in methods like .includes(). This challenge helped strengthen my understanding of: • Array traversal using loops • Conditional comparisons • Manual search logic • Returning Boolean results effectively 🌍 Though simple, this concept plays a big role in real-world applications like: ✅ Searching records in a dataset ✅ Validating user inputs ✅ Checking access permissions ✅ Matching values in dynamic arrays 💡 Every “basic” problem hides a core principle that drives advanced algorithms. Mastering small steps leads to giant leaps in logic building! #JavaScript #171DaysOfCode #ProblemSolving #LearnInPublic #BackToBasics #WebDevelopment #CodingChallenge #DeveloperMindset #LogicBuilding
To view or add a comment, sign in
-
-
🔼 Day 165 of #200DaysOfCode Today, I revisited a fundamental concept that plays a major role in data structures and algorithm design — sorting an array in ascending order using Bubble Sort (without built-in sort methods). 💡 Modern JavaScript gives us shortcuts like Array.sort(), but when we build the logic manually, we develop a much deeper understanding of: • Pairwise comparison • Value swapping in arrays • Nested looping structure • Time complexity (Bubble Sort → O(n²)) Sorting isn’t just a beginner concept — it’s the backbone of efficient searching, optimization, and real-world computational logic. 🔁 Going back to basics reminds me that advanced problem-solving ability is built on strong fundamentals, not shortcuts. 🌱 Every step forward in coding is supported by the basics we choose to master — and revisit. #JavaScript #200DaysOfCode #CodingChallenge #Sorting #Algorithms #WebDevelopment #DeveloperMindset #LearnInPublic #DSA #ProblemSolving
To view or add a comment, sign in
-
-
🚀 Master Regular Expressions (Regex) in JavaScript! Regex might look scary at first glance — but it’s one of the most powerful tools for text manipulation and validation 💪 Here’s a quick example 👇 const str = "My email is hello@example.com"; const pattern = /\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Z|a-z]{2,}\b/; const result = str.match(pattern); console.log(result); // Output: ["hello@example.com"] ✅ What’s happening here? \b → word boundary [A-Za-z0-9._%+-]+ → username part (letters, numbers, symbols) @ → literal [A-Za-z0-9.-]+ → domain name \.[A-Z|a-z]{2,} → top-level domain (like .com, .org, etc.) 🎯 Regex is great for: ✔ Email / phone / URL validation ✔ Extracting data from text ✔ Search-and-replace patterns ✔ Text sanitization 💡 Pro Tip: Use tools like regexr.com or regex101.com to test and visualize your patterns in real time. #JavaScript #Regex #WebDevelopment #Coding #Frontend #Programming #100DaysOfCode #DevCommunity #CodeNewbie #DeveloperTips #LearnToCode #JS #SoftwareEngineering #CleanCode #TechEducation
To view or add a comment, sign in
-
Start free on CSX and practice as you read: https://lnkd.in/eFtB-g27 In JavaScript, data types tell your code how to treat a value. Primitives are single values like text, numbers, and true/false. Composites group values together as labeled objects or ordered lists. Knowing the difference helps your conditions, loops, and functions behave predictably. Practice the data types lesson on CSX. Get instant feedback and beginner-friendly exercises. Follow for more tips.💻 ✨ #javascript #coding #webdevelopment #csx #datatypes #objects #arrays
To view or add a comment, sign in
-
Now, if I say implement 𝙡𝙚𝙛𝙩 𝙧𝙤𝙩𝙖𝙩𝙞𝙤𝙣 𝙗𝙮 𝙠 𝙫𝙖𝙡𝙪𝙚𝙨. The normal solution will be to just take the input of k and add a for loop for k times. But this is not the optimum solution. Add k = k % arr.length and add value in temp [i] variable by arr (i+k)% arr.length. This will be more efficient approach compared to earlier approach
|| SWE @ mPair Tech. || Backend || || Docker || GitHub actions || Nest JS || Micro Service || FastAPI ||
𝐃𝐒𝐀 𝐰𝐢𝐭𝐡 𝐉𝐚𝐯𝐚𝐬𝐜𝐫𝐢𝐩𝐭 01 𝐋𝐞𝐟𝐭 𝐑𝐨𝐭𝐚𝐭𝐢𝐨𝐧 𝐨𝐟 𝐚𝐧 𝐀𝐫𝐫𝐚𝐲 𝐛𝐲 𝟏 𝐢𝐧 𝐉𝐚𝐯𝐚𝐒𝐜𝐫𝐢𝐩𝐭 Ever needed to rotate array elements so the first item moves to the end? That’s called left rotation. ✅ Input:[1, 2, 3, 4, 5] ✅ After 1 Left Rotation: [2, 3, 4, 5, 1] 𝒍𝒆𝒕 𝒂𝒓𝒓 = [1, 2, 3, 4, 5]; 𝒍𝒆𝒕 𝒄𝒐𝒑𝒚 = 𝒂𝒓𝒓[0]; // 𝒔𝒕𝒐𝒓𝒆 𝒇𝒊𝒓𝒔𝒕 𝒆𝒍𝒆𝒎𝒆𝒏𝒕 𝒇𝒐𝒓 (𝒍𝒆𝒕 𝒊 = 0; 𝒊 < 𝒂𝒓𝒓.𝒍𝒆𝒏𝒈𝒕𝒉 - 1; 𝒊++) { 𝒂𝒓𝒓[𝒊] = 𝒂𝒓𝒓[𝒊 + 1]; // 𝒔𝒉𝒊𝒇𝒕 𝒆𝒍𝒆𝒎𝒆𝒏𝒕𝒔 𝒍𝒆𝒇𝒕 } 𝒂𝒓𝒓[𝒂𝒓𝒓.𝒍𝒆𝒏𝒈𝒕𝒉 - 1] = 𝒄𝒐𝒑𝒚; // 𝒑𝒖𝒕 𝒇𝒊𝒓𝒔𝒕 𝒆𝒍𝒆𝒎𝒆𝒏𝒕 𝒂𝒕 𝒕𝒉𝒆 𝒆𝒏𝒅 𝒄𝒐𝒏𝒔𝒐𝒍𝒆.𝒍𝒐𝒈(𝒂𝒓𝒓); // [2, 3, 4, 5, 1] This is a simple problem but help in mastering basics Happy Learning! #datastructures #algorithms #problemSolving #codingchallenge #learncoding #javascriptdeveloper #interviewprep
To view or add a comment, sign in
-
𝐃𝐒𝐀 𝐰𝐢𝐭𝐡 𝐉𝐚𝐯𝐚𝐬𝐜𝐫𝐢𝐩𝐭 01 𝐋𝐞𝐟𝐭 𝐑𝐨𝐭𝐚𝐭𝐢𝐨𝐧 𝐨𝐟 𝐚𝐧 𝐀𝐫𝐫𝐚𝐲 𝐛𝐲 𝟏 𝐢𝐧 𝐉𝐚𝐯𝐚𝐒𝐜𝐫𝐢𝐩𝐭 Ever needed to rotate array elements so the first item moves to the end? That’s called left rotation. ✅ Input:[1, 2, 3, 4, 5] ✅ After 1 Left Rotation: [2, 3, 4, 5, 1] 𝒍𝒆𝒕 𝒂𝒓𝒓 = [1, 2, 3, 4, 5]; 𝒍𝒆𝒕 𝒄𝒐𝒑𝒚 = 𝒂𝒓𝒓[0]; // 𝒔𝒕𝒐𝒓𝒆 𝒇𝒊𝒓𝒔𝒕 𝒆𝒍𝒆𝒎𝒆𝒏𝒕 𝒇𝒐𝒓 (𝒍𝒆𝒕 𝒊 = 0; 𝒊 < 𝒂𝒓𝒓.𝒍𝒆𝒏𝒈𝒕𝒉 - 1; 𝒊++) { 𝒂𝒓𝒓[𝒊] = 𝒂𝒓𝒓[𝒊 + 1]; // 𝒔𝒉𝒊𝒇𝒕 𝒆𝒍𝒆𝒎𝒆𝒏𝒕𝒔 𝒍𝒆𝒇𝒕 } 𝒂𝒓𝒓[𝒂𝒓𝒓.𝒍𝒆𝒏𝒈𝒕𝒉 - 1] = 𝒄𝒐𝒑𝒚; // 𝒑𝒖𝒕 𝒇𝒊𝒓𝒔𝒕 𝒆𝒍𝒆𝒎𝒆𝒏𝒕 𝒂𝒕 𝒕𝒉𝒆 𝒆𝒏𝒅 𝒄𝒐𝒏𝒔𝒐𝒍𝒆.𝒍𝒐𝒈(𝒂𝒓𝒓); // [2, 3, 4, 5, 1] This is a simple problem but help in mastering basics Happy Learning! #datastructures #algorithms #problemSolving #codingchallenge #learncoding #javascriptdeveloper #interviewprep
To view or add a comment, sign in
-
𝗪𝗵𝗲𝗻 𝗿𝗲𝗰𝘂𝗿𝘀𝗶𝗼𝗻 𝗳𝗶𝗻𝗮𝗹𝗹𝘆 𝗰𝗹𝗶𝗰𝗸𝘀! Recursion in JavaScript simply means a function calling itself again and again until it reaches a base case. At first it feels confusing, but once the logic hits, everything starts looking simple - just like this meme! It’s a powerful way to handle tasks like tree structures, nested data, factorials, and many smart solutions with clean code. Recursion helps in solving tasks like tree structures, nested data, factorials, Fibonacci series and many more complex problems in a clean and smart way. Sometimes the smartest code isn’t long… it’s just recursive. #JavaScript #Recursion #WebDevelopment #CodingJourney #TechLife #DevelopersIndia #LearningEveryday
To view or add a comment, sign in
-
-
When automating web scraping, treat your scraper like a mini browser, not just a request sender. Modern websites use dynamic JavaScript rendering, lazy loading, and anti-bot systems. Tools like Playwright or Selenium can mimic real human behavior (scrolling, waiting for elements, random delays) and drastically improve scraping reliability. Bonus tip: Always build retry + rotation logic (user agents, proxies, headers) into your scraper. It’s not about scraping faster, it’s about scraping smarter. #WebScraping #Automation #Python #DataEngineering #CodingTips #BackendDevelopment
To view or add a comment, sign in
-
Me, confidently typing: npx tailwindcss init -p …and BOOM 💣: ❌ 'tailwind' is not recognized or could not determine executable to run. 😭💀 💡 The “solution” (if you can call it that): ⬇️ Downgrade to v3 ⬇️ Yep. That’s IT. 🙃☕ 📚 Moral of the story: 1️⃣ hour of reading docs > 4️⃣ hours of rage, debugging, and begging AI 🤖🙏 ☕ To the brilliant engineers who remove basic commands just to “improve things”: Salut🫡 💻💡 To all devs out there—may your CLI work 😅🔥 , your coffee stay strong ☕⚡, and your debugging be short. 🚀✨ #DeveloperLife #TailwindCSS #Frontend #Debugging #BreakingChanges #CodingHumor #CoffeePowered #ProgrammerProblems #DevLife
To view or add a comment, sign in
-
Day 23/90 – 90 Days DSA Challenge Today I practiced another classic recursion problem — Sum of first N natural numbers using recursion 💡 🧠 Concept Recap: Recursion is when a function calls itself with a smaller input until it reaches a base condition. It’s like peeling an onion layer by layer — until you reach the core 🧅 ⚙️ Problem Statement: 👉 Write a function sum(n) that calculates the sum of the first n natural numbers. 🧩 Example: Input: 5 Process: 5 + 4 + 3 + 2 + 1 = 15 Output: 15 Time Complexity: O(n) 💾 Space Complexity: O(n) (due to call stack) ✨ Key takeaway: Recursion helps break down complex problems into smaller, simpler ones — it’s elegant, powerful, and mind-opening once you get the hang of it! #Day23 #DSA #Recursion #JavaScript #CodingChallenge #MechCode #LearningInPublic #FrontendDeveloper #CodeEveryday
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