-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
69 lines (59 loc) · 2.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Process Scheduling Simulator</title>
<link rel="stylesheet" href="style.css">
<script type="text/javascript" src="https://www.gstatic.com/charts/script.js"></script>
</head>
<!-- BODY -->
<body>
<!-- HEADER -->
<div class="container">
<div style="text-align: center; margin-bottom: 20px;">
<a href="about.html" style="text-decoration: none;">
<button style="padding: 8px 16px; background-color: purple; color: #fff; border: none; border-radius: 5px; cursor: pointer;">
About
</button>
</a>
<!-- scheduler -->
<div class="container">
<h1>Process Scheduling Simulator</h1>
<div class="input-section">
<label for="process-count">Number of Processes:</label>
<input type="number" id="process-count" class="input-field">
<button class="btn" onclick="addProcessFields()">Add Processes</button>
</div>
<br>
<div id="process-fields"></div>
<br>
<div class="algorithm-select">
<label for="algorithm">Select Algorithm:</label>
<select id="algorithm" class="input-field" onchange="toggleTQ()">
<option value="fcfs">First Come First Serve (FCFS)</option>
<option value="sjf">Shortest Job First (SJF)</option>
<option value="rr">Round Robin (RR)</option>
<option value="srtf">Shortest Remaining Time First (SRTF)</option>
<option value="priority">Priority Scheduling</option>
</select>
<label for="time-quantum">Time Quantum (for RR):</label>
<input type="number" id="time-quantum" class="input-field" disabled>
<label for="context">Context Switch:</label>
<input type="number" id="context" class="input-field" enabled>
</div>
<!-- RUN ALGOOOSS -->
<button class="btn" onclick="runAlgorithm()">Run Algorithm</button>
<div id="result" class="result"></div>
<br>
<!-- GANTT CHART -->
<div class="show-gantt">
<label for="show-gantt-checkbox">Show Gantt Chart:</label>
<input type="checkbox" id="show-gantt-checkbox" onchange="toggleGantt()">
</div>
<div id="gantt-chart" class="gantt-chart"></div>
</div>
<script src="script.js"></script>
<!-- </script> -->
</body>
</html>