Answers for "vars javascript"

3

how to write a variable in js

//choose the best for your solution
var myVariable = 22; //this can be a string or number. var is globally defined

let myVariable = 22; //this can be a string or number. let is block scoped

const myVariable = 22; //this can be a string or number. const is block scoped and
Posted by: Guest on June-03-2020
6

js variable

var Number = 5;
var String = "Hi!";
var boolen1 = true;
var boolen2 = false;
var array = [11, "Hi!", true];
var object = {age:11, speach:"Hi!", likes_Bananas:true};
Posted by: Guest on June-21-2020
6

javascript variable

var user_name = prompt("Please enter your name:", "Type here");
alert("Hello " + user_name);
Posted by: Guest on November-03-2020
0

how to instialise var in js

var variable-name = number;
/*eg*/
var a = 10;
Posted by: Guest on June-03-2020
0

variables javascript

var example = "hello";
document.write(example);// it will say hello when it runs
Posted by: Guest on February-25-2021
-1

vars javascript

var /*var*/ = /*What it does*/
Posted by: Guest on September-22-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language