what is "document" in the following code var x=10; document.write(x) | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

what is "document" in the following code var x=10; document.write(x)

Is document is a class in javascript?

18th Jul 2019, 9:24 AM
Muhammad Zain
Muhammad Zain - avatar
1 Answer
+ 1
document is an object. Classes are more likely to create similar objects (write is. a method of the document object).
18th Jul 2019, 9:54 AM
Airree
Airree - avatar