SGShikhar Guptainthecleancommit.hashnode.dev·Apr 15 · 6 min readFunctions in JavaScriptIn the previous blog, we learned how to control the flow of our program using conditions like if, else, and switch. Now your program can make decisions. But there is still a problem. Imagine writing t00
GGambitinjavascriptfromscratch.hashnode.dev·Apr 2 · 8 min readJs - FunctionsSimple function declaration Let's make a simple function that console logs "Hello" whenever called. function sayHello(){ console.log("Hello") } console.log(sayHello) // [Function: sayHello] sa00
RMRobert Muendoinjavascript-for-beginners.hashnode.dev·Mar 28 · 4 min readThe Power of Functions: Reusable Code Patterns in JavaScriptIntroduction Imagine writing the same lines of code every time you need to perform a task—calculating a total, formatting a date, or greeting a user. That repetition quickly makes code bloated, error-00
ASAkash Sangleinjavascript-this-keyword.hashnode.dev·Mar 22 · 6 min readThe this Keyword in JavaScript – Explained with Uber🚕 The Uber Analogy Imagine an Uber driver named Ravi gets a request on his app. The app shows: "Your current trip details" The word "your" means different things depending on who is looking at the ap00
SSSATYAM SHARMAinsatyamexxe.hashnode.dev·Mar 15 · 6 min readArray Methods Every living beings should knowJavaScript Array Methods That Quietly Change the Way You Think About Data If you’ve ever worked with arrays in JavaScript, you probably started with something like this: for (let i = 0; i < numbers.le00
AKAmardeep Kumarinjavascript-function-declaration-and-expresssion.hashnode.dev·Mar 15 · 9 min readFunction Declaration vs Function Expression: What’s the Difference?1. Introduction Hey Scroller! When you hear the word function in programming, what comes to mind first? Most likely, doing a specific task, right? Let’s understand this with a real-life example. Imagi00
PJPrakash Jangidinjs-blogs.hashnode.dev·Mar 15 · 5 min readFunction Declaration vs Function Expression: What’s the Difference?Functions are the most fundamental part of any programming language, which makes code resuable, readable and modular. Imagine a phone that doesn’t have a contacts list. Every time you want to call a f00
SSSATYAM SHARMAinsatyamexxe.hashnode.dev·Mar 15 · 3 min readArrow Functions in (JavaScript) A Simpler Way to Write Functions When writing JavaScript, we often create small helper functions. Earlier we used the traditional function syntax, but modern JavaScript introduced arrow functions to m00
JVJanardhan Vermainjavascript-function.hashnode.dev·Mar 15 · 5 min readFunction Declaration vs Function Expression: What’s the Difference?Suppose you need to perform an operation many times in code, for example finding the maximum of two numbers. Are you okay with writing the complete code again and again? let a = 10; let b = 20; let ma00
APAmruta Patilinamruta-patil.hashnode.dev·Mar 15 · 6 min readUnderstanding the Magic of this, call(), apply(), and bind() in JavaScriptIntroduction JavaScript is a flexible language, and one of the most powerful concepts in it is the function context.When working with functions, we often need to know which object is executing the fun00