-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
80 lines (57 loc) · 2.17 KB
/
index.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta name="viewport" content=
"width=device-width, initial-scale=1.0">
<!-- CSS file Included -->
<link rel="stylesheet"
type="text/css" href="style.css">
<!-- JavaScript file included -->
<script src="script.js"></script>
</head>
<body>
<div id="main">
<h1>TIC TAC TOE</h1>
<!-- Game Instructions -->
<p id="ins" align="center">
<h3>Instructions</h3>
<para id="in" align="left">
Tap on any box<br>
First Player starts as <b>Player X</b><br>
Second Player as <b>Player 0</b><br><br>
</para>
</p>
<br><br>
<!-- 3*3 grid of Boxes -->
<input type="text" id="b1" onclick=
"myfunc_3(); myfunc();" readonly>
<input type="text" id="b2" onclick=
"myfunc_4(); myfunc();" readonly>
<input type="text" id="b3" onclick=
"myfunc_5(); myfunc();" readonly>
<br><br>
<input type="text" id="b4" onclick=
"myfunc_6(); myfunc();" readonly>
<input type="text" id="b5" onclick=
"myfunc_7(); myfunc();" readonly>
<input type="text" id="b6" onclick=
"myfunc_8(); myfunc();" readonly>
<br><br>
<input type="text" id="b7" onclick=
"myfunc_9(); myfunc();" readonly>
<input type="text" id="b8" onclick=
"myfunc_10();myfunc();" readonly>
<input type="text" id="b9" onclick=
"myfunc_11();myfunc();" readonly>
<!-- Grid end here -->
<br><br><br>
<!-- Button to reset game -->
<button id="but" onclick="myfunc_2()">
RESET
</button>
<br><br>
<!-- Space to show player turn -->
<p id="print"></p>
</div>
</body>
</html>