-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
92 lines (89 loc) · 4.55 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
81
82
83
84
85
86
87
88
89
90
91
92
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>jS Calculator</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.16.0/umd/popper.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js"></script>
<link rel="stylesheet" href="index.css">
<script src="index.js"></script>
<link rel="icon" href="https://img.icons8.com/fluent/48/000000/calculator.png" type="image/x-icon">
</head>
<body>
<div class="container mt-3">
<div class="row">
<div class="col-md-3"> </div>
<div class="col-md-6 mt-2 pt-5 pl-5 pr-5" id="cald">
<h2 class="text-center">Calculator</h2>
<div class="text-right p-3 bg-light" id="inp-f">
<h1 id="inp">0</h1>
<h3 id="out">0</h3>
</div>
<div class="text-center mt-2">
<div class="row mt-2">
<div class="col-3">
<button onclick="buttonp(7)" class="btn btn-lg btn-light w-100 p-3">7</button>
</div>
<div class="col-3">
<button onclick="buttonp(8)" class="btn btn-lg btn-light w-100 p-3">8</button>
</div>
<div class="col-3">
<button onclick="buttonp(9)" class="btn btn-lg btn-light w-100 p-3">9</button>
</div>
<div class="col-3">
<button onclick="preOp('+')" class="btn btn-lg btn-secondary w-100 p-3">+</button>
</div>
</div>
<div class="row mt-2">
<div class="col-3">
<button onclick="buttonp(4)" class="btn btn-lg btn-light w-100 p-3">4</button>
</div>
<div class="col-3">
<button onclick="buttonp(5)" class="btn btn-lg btn-light w-100 p-3">5</button>
</div>
<div class="col-3">
<button onclick="buttonp(6)" class="btn btn-lg btn-light w-100 p-3">6</button>
</div>
<div class="col-3">
<button onclick="preOp('-')" class="btn btn-lg btn-secondary w-100 p-3">-</button>
</div>
</div>
<div class="row mt-2">
<div class="col-3">
<button onclick="buttonp(1)" class="btn btn-lg btn-light w-100 p-3">1</button>
</div>
<div class="col-3">
<button onclick="buttonp(2)" class="btn btn-lg btn-light w-100 p-3">2</button>
</div>
<div class="col-3">
<button onclick="buttonp(3)" class="btn btn-lg btn-light w-100 p-3">3</button>
</div>
<div class="col-3">
<button onclick="preOp('*')" class="btn btn-lg btn-secondary w-100 p-3">*</button>
</div>
</div>
<div class="row mt-2">
<div class="col-3">
<button onclick="del()" class="btn btn-lg btn-danger w-100 p-3">C</button>
</div>
<div class="col-3">
<button onclick="buttonp(0)" class="btn btn-lg btn-light w-100 p-3">0</button>
</div>
<div class="col-3">
<button onclick="equal()" class="btn btn-lg btn-success w-100 p-3">=</button>
</div>
<div class="col-3">
<button onclick="preOp('/')" class="btn btn-lg btn-secondary w-100 p-3">/</button>
</div>
</div>
<p class="text-right mt-3 mb-3"><strong>Developed By:</strong><br> M. Zuraiz Zafar</p>
</div>
</div>
<div class="col-md-3"> </div>
</div>
</div>
</body>
</html>