-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathalgorithm3.html
117 lines (101 loc) · 4.78 KB
/
algorithm3.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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
<!DOCTYPE html>
<html>
<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">
<meta charset="UTF-8">
<title>FCFS Disk Scheduling Algorithm</title>
<link rel="stylesheet" type="text/css" href="algorithm3.css">
<link rel="stylesheet" href="animation.css">
</head>
<body>
<header>
<h1 class="logo">OPERATING SYSTEM PROJECT</h1>
<nav>
<ul class="nav-links">
<li><a href="index.html">Home</a></li>
<li><a href="read_more.html">Documentation</a></li>
<!-- <li><a href="simulators.html" target="_blank">Simulators</a></li> -->
<li class="dropdown">
<a href="simulator.html" class="dropbtn">Simulators</a>
<div class="dropdown-content">
<a href="priority_preemptive.html">Priority Preemptive</a>
<a href="fcfs_disk_scheduling.html">FCFS Disk Scheduling</a>
<a href="petersons.html">Peterson's Solution</a>
<a href="optimal_page_replacement.html">Optimal Page Replacement</a>
</div>
</li>
<li><a href="team.html">About Us</a></li>
<li><a href="contact.html">Contact Us</a></li>
</ul>
</nav>
</header>
<section class="container_docs" data-aos="zoom-in-up">
<h1>What is First-Come First-Serve Disk Scheduling Algorithm</h1>
<p>First-Come, First-Serve (FCFS) is a disk scheduling algorithm in which the disk access requests are served in the
order in which they arrive, also known as a FIFO (First-In-First-Out) method. This means that the request that is
first in the queue will be serviced first, regardless of its location on the disk. <br><br>
The FCFS algorithm is simple and easy to implement, but it may not be the most efficient scheduling algorithm
because it does not take into account the distance between the current position of the disk arm and the location
of the next request. This can result in longer seek times and increased disk access time.
<br>
</p>
<h4>
<li>Advantages of First-Come First-Serve Disk Scheduling Algorithm</li>
</h4>
<p>FCFS is a straightforward scheduling algorithm that does not require complex calculations or overhead. It is
easy to implement in software and hardware. <br><br>
FCFS is a fair scheduling algorithm because it serves the disk access requests in the order in which they
arrive. This means that each request has an equal chance of being serviced, and no request is given preferential
treatment. <br><br>
FCFS guarantees that all disk access requests will eventually be serviced, even if some requests have to wait
for a long time. This prevents any request from being starved of disk access. <br><br>
FCFS does not reorder the disk access requests, which means that it does not interfere with the order of data
on the disk. This can be important in certain applications where the order of data is important, such as video or
audio playback. <br><br>
</p>
<h4>
<li>Disadvantages of First-Come First-Serve Disk Scheduling Algorithm</li>
</h4>
<p>Long waiting times: FCFS may result in some requests waiting for a long time to be serviced, especially if there
are other requests ahead of them in the queue. This can lead to increased disk access time and lower system
performance. <br><br>
Inefficient use of disk: FCFS does not take into account the location of the next request on the disk, which can
result in unnecessary disk head movement and longer seek times. This can cause decreased efficiency and slower
overall performance of the system. <br><br>
No priority handling: FCFS does not consider the priority of the requests, which can result in lower priority
requests waiting for a long time to be serviced while higher priority requests are delayed. This can lead to
inefficient use of system resources and lower system performance. <br><br>
</p>
<br>
</section>
<div class="prompt">
<button id="prompt-button">
<img src="quiz.jpg" alt="Chatbot Icon">
</button>
</div>
<!-- <h1>FCFS Disk Scheduling Algorithm</h1>
<label for="queue">Enter the disk request queue:</label>
<input type="text" id="queue" placeholder="e.g. 98,183,37,122,14,124,65,67">
<button onclick="simulate()">Simulate</button>
<table>
<thead>
<tr>
<th>Request</th>
<th>Start</th>
<th>End</th>
</tr>
</thead>
<tbody id="output-body"></tbody>
</table>
<script src="script_disk.js"></script>
<script src="https://cdn.jsdelivr.net/chartist.js/latest/chartist.min.js"></script> -->
<script>
const promptButton = document.getElementById("prompt-button");
promptButton.addEventListener("click", function() {
window.location.href = "quiz.html";
});
</script>
</body>
</html>