-
Notifications
You must be signed in to change notification settings - Fork 20
/
index.html
93 lines (87 loc) · 4.27 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
93
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Scheduling Algorithms</title>
<link rel="icon" href="favicon.png">
<link rel="stylesheet" href="style.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
</head>
<body>
<h1>Scheduling Algorithms</h1>
<h3>Instructions :</h3>
<ol class="instructions">
<li>Tiebreaker is Process ID.</li>
<li>When burst time is criteria, total burst time is taken into consideration.</li>
<li>Context Switch not considered at start and end of processes.</li>
</ol>
<h3>Preferences :</h3>
<ol class="preferences">
<li>
Priority : 1 is
<button id="priority-toggle-btn">
<span id="priority-preference">high</span>
<i class="fa fa-refresh"></i>
</button>
</li>
<form id="algorithms-form">
<label for="algo"><h3>Algorithms : </h3></label>
<select name="algo" id="algo">
<option value="fcfs">First Come First Serve (FCFS)</option>
<option value="sjf">Shortest Job First (SJF)</option>
<option value="ljf">Longest Job First (LJF)</option>
<option value="srtf">Shortest Remaining Job First (SRTF)</option>
<option value="lrtf">Longest Remaining Job First (LRTF)</option>
<option value="rr">Round Robin</option>
<option value="pnp">Priority (Non Preemptive)</option>
<option value="pp">Priority (Preemptive)</option>
<option value="hrrn">Highest Response Ratio Next (HRRN)</option>
</select>
</form>
<br>
<table class="main-table">
<thead>
<tr>
<th class="process-id">Process ID</th>
<th class="priority hide">Priority</th>
<th class="arrival-time">Arrival Time</th>
<th class="process-time" colspan="1">Process Time</th>
</tr>
</thead>
<tbody>
<tr>
<td class="process-id" rowspan="2">P1</td>
<td class="priority hide" rowspan="2"><input type="number" min="1" step="1" value="1"></td>
<td class="arrival-time" rowspan="2"><input type="number" min="0" step="1" value="0"> </td>
<td class="process-time cpu process-heading" colspan="">CPU</td>
<td class="process-btn"><button type="button" class="add-process-btn">+</button></td>
<td class="process-btn"><button type="button" class="remove-process-btn">-</button></td>
</tr>
<tr>
<td class="process-time cpu process-input"><input type="number" min="1" step="1" value="1"> </td>
</tr>
</tbody>
</table>
<br>
<button type="button" class="add-btn">Add Process</button>
<button type="button" class="remove-btn">Delete Process</button>
<div id="context-switch-div">
<br>
<label for="context-switch">Context Switch Time : </label>
<input type="number" name="Context Switch" id="context-switch" min="0" step="1" value="0">
</div>
<div id="time-quantum" class="hide">
<br>
<label for="tq">Time Quantum : </label>
<input type="number" name="Time Quantum" id="tq" min="1" step="1" value="1">
</div>
<br>
<button type="button" id="calculate">Calculate</button>
<button type="button" id="reset" onClick="window.location.reload();">Reset</button>
<div id="output"></div>
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.9.4/Chart.min.js" integrity="sha512-d9xgZrVZpmmQlfonhQUvTR7lMPtO7NkZMkA0ABN3PHCbKA5nqylQ/yWlFAyY6hYgdF1Qh6nYiuADWwKB4C2WSw==" crossorigin="anonymous"></script>
<script src="script.js"></script>
</body>
</html>