-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path00_script.js
More file actions
116 lines (83 loc) · 2.56 KB
/
00_script.js
File metadata and controls
116 lines (83 loc) · 2.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
// let str = "yuvraj is the best ";
// for ( let i of str) {
// console.log("i = " , i);
// }
// let str = "javascript" ;
// let size = 0;
// for ( let val of str) {
// console.log ("val=" , val);
// size++ ;
// }
// console.log("string size" = size);
// for in loop
// let student = {
// name: "yuvraj singh",
// age: 90,
// cgpa: 8.7,
// };
// for (let key in student) {
// console.log("key = " , key ,"value= ", student[key]);
// }
// for (let num = 0 ; num <= 100 ; num++) {
// if ((num%2 != 0 ))
// console.log("num =" , num);
// }
// let gameNum = "30" ;
// let userNum = prompt (" guess the game number : ");
// while (userNum != gameNum) {//game
// userNum = prompt (" you entered the wrong number guess again: ");
// }
// console.log ("congrats you entered the rigtht number ");
// let obj = {
// item: "pen",
// price: 10 ,
// };
// let output = `the cost of ${obj.item}is`
// console.log("the cost of " , obj.item, "is", object.price, "rupees");
// let specialstring = ` this is a template literal ${1 + 2 + 3}`;
// console.log(specialstring);
// let fullname = prompt("enter your full name");
// let username = "@" + fullname;
// console.log(username);
// let marks = ["10", "20 ", "50", "90"];
// console.log(marks);
// let heroes = [ " thor" , "batman" , "superman" , "dad" , "joker"];
// for (let idx= 0 ; idx < heroes.length ; idx++) {
// console.log(heroes[idx]);
// }
// let heroes = [ " thor" , "batman" , "superman" , "dad" , "joker"];
// for (let hero of heroes) {
// console.log(hero.toUpperCase());
// }
// let mark = [85, 94 , 68, 89];
// let su= 0 ;
// for (let val of mark) {
// su=+ val;
// }
// let avg = su/marks.length;
// console.log(`avg marks of the class = ${avg}`);
// let marks = [86 , 56, 89, 65, 32];
// let sum
// let marks = [ 56, 76, 64, 56, ];
// let sum = 0 ;
// for ( let val of marks){
// sum += val;
// }
// let avg = sum/marks.length;
// console.log(`avg marks of the class = ${avg}`)
// let items = [250, 645 ,300, 900 ,50]
// let i = 0 ;
// for (let i = 0 ; i < items.length ; i++){
// let offer = val/10 ;
// items[i] = items[i] - offer;
// console.log(`value after offer= ${val}`);
// i++;
// }
const accountID = 122345;
let accountEMAIL = "yuvrjsingh.18818@gmail.com"
var accountPASSWORD = "2989219302938"
accountCITY = "FARIDABAD"
let accountSTATE;
console.table ([accountID,accountEMAIL,accountPASSWORD,accountCITY,accountSTATE])
//do not use var variable in modern world
//becuase of issue in black scope and functional scope//