What is the difference between constant() and define() ? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

What is the difference between constant() and define() ?

answer this question in bullet points please.

31st Oct 2022, 6:15 AM
Zeeshan Salam
Zeeshan Salam - avatar
2 Answers
+ 3
define() - initialize the constant. constant() - returns the value of the constant. defined() - Checks the existence of a constant
31st Oct 2022, 7:24 AM
Roland
Roland - avatar
+ 2
Thanks Roland
31st Oct 2022, 7:25 AM
Zeeshan Salam
Zeeshan Salam - avatar