forked from zxcodes/Calculator
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
50 lines (46 loc) · 2.25 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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="description" content="" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="stylesheet" href="dark.css" id="theme" />
<link href="https://fonts.googleapis.com/css2?family=Open+Sans:wght@300&display=swap" rel="stylesheet" />
</head>
<body>
<div class="wrapper">
<div class="container">
<div class="first-row">
<input type="text" name="result" class="result" id="result" value="" placeholder="Result" readonly />
<input type="button" value="C" onclick="clearScreen()" class="clear" />
</div>
<div class="second-row">
<input type="button" value="1" onclick="liveScreen(1)" id="one" />
<input type="button" value="2" onclick="liveScreen(2)" id="two" />
<input type="button" value="3" id="three" onclick="liveScreen(3)" />
<input type="button" value="+" onclick="liveScreen('+')" />
</div>
<div class="third-row">
<input type="button" value="4" id="four" onclick="liveScreen(4)" />
<input type="button" value="5" id="five" onclick="liveScreen(5)" />
<input type="button" value="6" id="six" onclick="liveScreen(6)" />
<input type="button" value="-" onclick="liveScreen('-')" />
</div>
<div class="fourth-row">
<input type="button" value="7" id="seven" onclick="liveScreen(7)" />
<input type="button" value="8" id="eight" onclick="liveScreen(8)" />
<input type="button" value="9" id="nine" onclick="liveScreen(9)" />
<input type="button" value="x" onclick="liveScreen('*')" />
</div>
<div class="fifth-row">
<input type="button" value="/" onclick="liveScreen('/')" />
<input type="button" value="0" id="zero" onclick="liveScreen(0)" />
<input type="button" value="." class="dot" onclick="liveScreen('.')" />
<input type="button" value="=" onclick="result.value = eval(result.value)" />
</div>
<!-- Fontawesome Script -->
<script src="https://kit.fontawesome.com/f28b055962.js" crossorigin="anonymous"></script>
<script src="script.js" sync defer></script>
</body>
</html>