-
Notifications
You must be signed in to change notification settings - Fork 4
/
Tic-tac.html
63 lines (44 loc) · 1.78 KB
/
Tic-tac.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Tic-Tac</title>
<script language="javascript"></script>
<script src="Tic-Tac.js"></script>
<link rel="stylesheet" href="Tic-Tac.css">
</head>
<body>
<div id="main">
<h1>TIC TAC TOE</h1>
<!-- Game Instructions -->
<p id="ins">Game starts by just Tap on box
<br><br>First Player starts as
<strong>Player <em> X</em></strong><br>And<br>Second Player as <strong>Player <em> Y</em></strong>
</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>