1
$\begingroup$

My understanding is that in a programming language, built-ins are bindings that exist without the user having to make them. (Like + to its referent, for example.)

My understanding of a constant literal is that it is a variable whose name encodes its value. (Like 3, or {"Name": "Steve", "age": 47} in JS.

Is a constant literal considered a type of built-in?

$\endgroup$

1 Answer 1

2
$\begingroup$

A literal is not a variable. See https://en.wikipedia.org/wiki/Literal_(computer_programming).

I wouldn't consider a literal a "built-in", but I'm not familiar with a precise formal definition of "built-in".

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.