ELI5: Explain Like I'm 5

Name binding

Okay kiddo, when we want to use a toy or a game, we usually give it a name, right? That way we can ask for it or talk about it easily.

In a similar way, programming languages also give names to things they use like variables, functions or classes so that they can be easily identified and used later in the code.

This process is called name binding. It’s like creating a link between the name we give something and the actual thing itself. This link helps the computer understand which thing we are referring to when we use its name in the code.

For example, imagine we want to play with our toy car called “Lightning McQueen”. We’ll always use its name to refer to it because that’s what we’ve named it.

Similarly, when we write code, we give names to the things we use, like a variable called “score” or a function called “add”. Whenever we need to use those things later on in the code, we’ll use their names so the computer knows what we mean.

That’s name binding! It’s just like giving names to our toys so we can find them easily when we want to play with them.
Related topics others have asked about: