surffishin07 surffishin07
  • 17-11-2019
  • Computers and Technology
contestada

Which of the following is a valid JavaSript statement?
a. If (x = 5) x == 2 * x;
b. if (x = 5) x =2* x;
c. if (x == 5) x == 2 * x;
d. if (x == 5) x = 2 * x;​

Respuesta :

wyskoj
wyskoj wyskoj
  • 17-11-2019

Answer:

D

Explanation:

A and B are not valid because you cannot use "=" as a comparator (you must use "==" or "===").

C is not valid because the expression after the conditional is not a statement (it uses "==" instead of "=")

Answer Link
michaelarmstrong1337 michaelarmstrong1337
  • 18-11-2019

It is D if (x == 5) x = 2 * x;​

Answer Link

Otras preguntas

In the years leading up to the American revolution the committee of correspondence were most important because they
Your study guide should include important dates of events even if you think you will not be tested on them. True or false
modifying your results to match your prediction is an acceptable action when using scientific method true of false
Teacher asked the fifth class students to choose the best name games, 1/8 of students chosen the football game, the number of students that chosen the football
differ between bird and bat​
Fill in the blank in the following sentence with the appropriate imperfect form of the verb estar below. Esta mañana mi madre ________ muy cansada.
Imagine you are an astronaut and just got thrown off a spaceship. There is no friction and no gravity. Describe your motion.
4x^2 -9 Factor completely
which scenario can the following graph describe? A)the total time a kite is up in the air as it goes up for a little bit ,comes down and then stays aloft B)
How do I make an equation out of a word problem?