- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathif_else2.html
More file actions
Latest commit
62 lines (44 loc) · 1.13 KB
/
Copy pathif_else2.html
File metadata and controls
62 lines (44 loc) · 1.13 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
<!DOCTYPE html>
<htmllang="en">
<head>
<metacharset="UTF-8">
<title>demo</title>
</head>
<body>
<h4>Adult Age Checking</h4>
<inputtype="text" name="" value="" id="agF1" />
<inputtype="button" name="" value="Age Check" onclick="ageChk()" />
<pid="demo"></p>
<script>
functionageChk(){
varagV=document.getElementById('agF1').value;
if(isNaN(agV)){
document.getElementById('demo').innerHTML='Not a Valid Number';
}else{
document.getElementById('demo').innerHTML=(agV>18) ? "Adult Person" : "Under 18+";
}
}
</script>
<script>
varx=10;
varxx=0;
varxxx=0;
for(i=0;i<x;i++){
if(i==3){
xx++
continue;
}
xxx+='number is'+i+'<br/>'
}
if(xx>0){
document.write('3 exist');
}else{
document.write('3 not exist');
}
document.write(xxx);
</script>
<br/><br/><br/><br/><br/><br/><br/>
<br/><br/><br/><br/><br/><br/><br/>
<br/><br/><br/><br/><br/><br/><br/>
</body>
</html>