Suppose that a disk drive has 5,000 cylinders, numbered 0 to 4,999. The drive is currently serving a request at cylinder 2,150, and the previous request was at cylinder 1,805. The queue of pending requests, in FIFO order, is:

Answers

Answer 1

Answer:

The queue pending requests of FIFO order is ;

86, 1470, 1774, 948, 1509, 1022, 1750, 130.

Explanation:

The FCFS schedule is 143, 86, 1470, 913, 1774, 948, 1509, 1022, 1750, 130.

Total seek distance is 7081.

The SSTF schedule is 143, 130, 86, 913, 948, 1022, 1470, 1509, 1750, 1774.

Total seek distance is 1745.

The LOOK schedule is 143, 913, 948, 1022, 1470, 1509, 1750, 1774, 130, 86.

Total seek distance is 3319.

The SCAN schedule is 143, 913, 948, 1022, 1470, 1509, 1750, 1774, 4999, 130, 86.

Total seek distance is 9769.


Related Questions

Create a class called Circle, which has (i) an attribute radius, (ii) a method that returns the current radius of a circle object, (iii) a method that allows the user to reset the radius of a circle, (iv) a method that calculates the area of the circle, and (v) a constructor that takes a number as parameter input and assign the number as the initial value of radius.

Answers

Answer:

Explanation:

The following class is written in Java. I created the entire Circle class with each of the methods and constructor as requested. I also created a tester class to create a circle object and call some of the methods. The output can be seen in the attached picture below for the tester class.

class Circle {

   double radius;

   public Circle(double radius) {

       this.radius = radius;

   }

   public double getRadius() {

       return radius;

   }

   public void resetRadius() {

       radius = 0;

   }

   public double calculateArea() {

       double square = Math.pow((Math.PI * radius), 2);

       return square;

   }

}

(2) What are the limitations of portable computer? ​

Answers

Answer:

Most portable computer are not upgradable and they have a lower specification than most desktop systems

Problema 2018.3.2 - Cheated dice
Costica is on vacation and his parents sent him to the country. There he gets terribly bored and looking through his grandfather's closet, he came across a bag full of dice. Having no one to play dice with, but it seemed to him that some of the dice were heavier than the others, Costica chose a dice and started to test it by throwing it with him and noting how many times each face fell. He then tries to figure out whether the dice are rolled or not, considering that the difference between the maximum number of appearances of one face and the minimum number of occurrences (of any other face) should not exceed 10% of the total number of throws.
Requirement
Given a number N of dice rolls and then N natural numbers in the range [1: 6] representing the numbers obtained on the rolls, determine whether the dice is tricked according to the above condition.
Input data
From the input (stdin stream) on the first line reads the natural number N, representing the number of rolls. On the following N lines there is a natural number in the range [1: 6] representing the numbers obtained on throws.
Output data
At the output (stdout stream) a single number will be displayed, 0 or 1, 0 if the dice are normal, and 1 if it is cheated.
ATTENTION to the requirement of the problem: the results must be displayed EXACTLY in the way indicated! In other words, nothing will be displayed on the standard output stream in addition to the problem requirement; as a result of the automatic evaluation, any additional character displayed, or a display different from the one indicated, will lead to an erroneous result and therefore to the qualification "Rejected".
Restrictions and clarifications
1. 10 ≤ N ≤ 100
2. Caution: Depending on the programming language chosen, the file containing the code must have one of the extensions .c, .cpp, .java, or .m. The web editor will not automatically add these extensions and their absence makes it impossible to compile the program!
3. Attention: The source file must be named by the candidate as: . where name is the last name of the candidate and the extension (ext) is the one chosen according to the previous point. Beware of Java language restrictions on class name and file name!
Input data

10
6
6
6
6
6
6
6
6
6
6
Output data
1

Roll the dice 10 times, all 10 rolls produce the number 6. Because the difference between the maximum number of rolls (10) and the minimum number of rolls (0) is strictly greater than 10% of the total number of rolls (10% of 10 is 1), we conclude that the dice are oiled.

Input data
10
1
4
2
5
4
6
2
1
3
3
Output data
0

Throw the dice 10 times and get: 1 twice, 2 twice, 3 twice, 4 twice, 5 and 6 at a time. Because the difference between the maximum number of appearances (two) and the minimum number of occurrences (one) is less than or equal to 10% of the total number of throws (10% of 10 is 1), we conclude that the dice are not deceived.

Answers

Answer:

???????????

Explanation:

??????:& oh??

Blockchain technology provides what main benefits for the SUber dApp? The ability to link disparate users The ability to connect users with providers The ability to communicate with other smart devices the ability to communicate with other users

Answers

Answer: The ability to communicate with other users

Explanation:

Blockchain technology refers to a structure which help in the storage of transactional records of people in databases, which is referred to as the chain. It is connected in a network by peer-to-peer nodes.

One main benefit of the Blockchain technology for the SUber dApp is that it gives one the ability to communicate with other users.

Write a program that allows two players to play the Tic-Tac-Toe game. One of the players can be the computer or human, the other must be human. Your program must contain the class ticTacToe to implement a ticTacToe object. Include a 3 by 3 two-dimensional array, as a private member variable, to create the board. If needed, include additional member variables

Answers

Answer:

Explanation:

The following is a tictactoe game written in Java with all the necessary variables and methods needed for the game to function correctly. The game plays against the computer which randomly chooses a position to play every round. Due to technical difficulties the code was added as a txt file below and the output was added as a picture.

write a program that takes as input a number of kilometers and prints the corresponding number of nautical miles.

Answers

Answer:

try this

Explanation:

km = float(input('Kilometers: '))

nm = (km * 5400) / 10000

print('%0.4f km = %0.4f Nautical Miles' %(km,nm))

Write the recursive method printNumber. The public static method named printNumber takes two parameters. The first parameter is an integer array called nums, and the second is parameter is an even int called index. The return value is an integer that is the product of the even index values in nums whose index is less than or equal to index. Assume that the array nums has length >

Answers

Answer:

The function is as follows:

public static void printNumber(int nums[],int index){

if (index < 0) {

 System.out.print(nums[0]);

 return;  }

if (index % 2 == 0){

    if(index!=0){

 nums[index-2]*=nums[index];}  }

printNumber(nums, index - 1);

}

Explanation:

To do this, we need to save the required product in the 0 index element of the array.

This defines the function

public static void printNumber(int nums[],int index){

If the index variable < 0,

if (index < 0) {

Print the 0 index as the product [i.e. the calculated product]

 System.out.print(nums[0]);

This ends the recursion

 return;  }

If the current array index is even

if (index % 2 == 0){

Check if index is not 0

    if(index!=0){

If both conditions are valid, calculate the product and save the result in index - 2 element. The final result is then saved in the 0 index

 nums[index-2]*=nums[index];}  }

Call the function while the base case has not been executed

printNumber(nums, index - 1);

}

What are the objects in object-oriented programming language?

Answers

Answer:

An object is an abstract data type with the addition of polymorphism and inheritance. Rather than structure programs as code and data, an object-oriented system integrates the two using the concept of an "object". An object has state (data) and behavior (code). Objects can correspond to things found in the real world.

hope it helps ya mate.

what is a web browser​

Answers

Answer:

web browser

Explanation:

.........;)

Question # 2 Multiple Select You wrote a program to compare the portion of drivers who were on the phone. Which statements are true? Select 4 options. Even when confident that the mathematical calculations are correct, you still need to be careful about how you interpret the results. Your program compared an equal number of male and female drivers. You could modify the program to allow the user to enter the data. It is important to test your program with a small enough set of data that you can know what the result should be. A different set of observations might result in a larger portion of male drivers being on the phone.

Answers

Answer: A different set of observations might result in a larger portion of male drivers being on the phone.

You could modify the program to allow the user to enter the data.

Even when confident that the mathematical calculations are correct, you still need to be careful about how you interpret the results.

It is important to test your program with a small enough set of data that you can know what the result should be.

Explanation: Got it right

what is the value of 2020/20×20​

Answers

Answer:.5.05

Explanation:...maths

Answer:

5.05

Explanation:

2020/400= 5.05

HOPE IT HELPED AND GOOD LUCK!!

Counting the character occurrences in a file
For this task you are asked to write a program that will open a file called “story.txt”
and count the number of occurrences of each letter from the alphabet in this file.
At the end your program will output the following report:
Number of occurrences for the alphabets:
a was used – times.
b was used – times.
c was used – times…. …and so, on
Assume the file contains only lower-case letters and for simplicity just a single
paragraph. Your program should keep a counter associated with each letter of the
alphabet (26 counters) [Hint: Use array]
Your program should also print a histogram of characters count by adding
a new function print Histogram (int counters []). This function receives the
counters from the previous task and instead of printing the number of times each
character was used, prints a histogram of the counters.

Answers

Answer:

hope this helps!

Explanation:

#include <iostream>

#include <fstream>

using namespace std;

void print_histogram(int counter[26])

{

   for(int i = 0; i < 26; ++i){

       cout << (char)(i+97) << " ";

       for(int j = 0; j < counter[i]; ++j){

           cout << (char)254;

       }

       cout << endl;

   }

}

int main()

{

   int counter[26] = {0};

   string filename = "data.txt";

   char byte = 0;

   // opens file in read mode

   ifstream input_file(filename);

   if (!input_file.is_open()) {

       cerr << "Could not open the file - '"

            << filename << "'" << endl;

       return EXIT_FAILURE; // exit if not opened

   }

   // reads every character from the file

   while(input_file.get(byte)){

       if(byte >= 97 && byte <= 122){

           ++counter[byte-97];

       }

   }

   print_histogram(counter); // required print histogram function

   return 0;

}

Write a program that will create an array of random numbers and output the values. Then output the values in the array backwards. SPECIFICATIONS: File name: ArrayBackwards.java Your program must make use of at least one method other than main()to receive full credit (methods can have a return type of void). Suggestion: create and populate the array in the main() method. Make a method for Step 3 below and send in the array as a parameter. Make another method for Step 4 and send in the array as a parameter.

Answers

Answer:

The program is as follows:

import java.util.*;

public class Main{

public static void backward(int [] Rndarray, int lnt){

    System.out.print("Reversed: ");

    for(int itm = lnt-1;itm>=0;itm--){

        System.out.print(Rndarray[itm]+" ");     } }

public static void main(String[] args) {

 Scanner input = new Scanner(System.in);

 int lnt = input.nextInt();

 Random rd = new Random();

 int [] Rndarray = new int[lnt];

 for (int itm = 0; itm < lnt; itm++) {

        Rndarray[itm] = rd.nextInt();

        System.out.print(Rndarray[itm]+" ");

     }

     System.out.println();

 backward(Rndarray,lnt); }}

Explanation:

This defines the backward() method

public static void backward(int [] Rndarray, int lnt){

This prints string "Reversed"

    System.out.print("Reversed: ");

This iterates through the array

    for(int itm = lnt-1;itm>=0;itm--){

Each element is then printed, backwards

        System.out.print(Rndarray[itm]+" ");     } }

The main begins here

public static void main(String[] args) {

 Scanner input = new Scanner(System.in);

This gets the array length

int  n = input.nextInt();

This creates a Random object

Random rd = new Random();

This declares the array

 int [] Rndarray = new int[lnt];

This iterates through the array for input

 for (int itm = 0; itm < lnt; itm++) {

This generates a random number for each array element

        Rndarray[itm] = rd.nextInt();

This prints the generates number

        System.out.print(Rndarray[itm]+" ");

     }

This prints a new line

     System.out.println();

This passes the array and the length to backward() method

 backward(Rndarray,lnt); }}

i cant tell if tubbo is a bee or a goat
or could he be human in the smp

Answers

Answer:

Tubbo is a goat or ram on the Dream SMP.

Explanation:

Since Jschlatt was his father and he's a ram, Tubbo is a ram.

Answer:

yes, the first person`s answer is correct! On the dsmp, Tubbo is a goat, since is father was one as well. The only place he is a bee is the osmp, or Origins smp. when Tubbo first joined the dsmp, he was known for his obsession with bees, which carried into his reputation entirely.

:]

Consider the following sequence of page references: 1 2 3 3 4 4 1 4 1 3 4. Determine how many page faults will occur with LRU(Least Recently Used) for each of the following algorithms, assuming there are only 2 physical page frames and that both are initially empty.

Answers

Answer:

7 page faults

Explanation:

I have created a small Java program that can be seen in the attached picture below. This Java program uses an LRU algorithm in order to find the number of page faults within an array of page references from the references given in the question. Using these references, and the java program we can see that there are a total of 7 page faults. This can be seen in the output highlighted by red in the picture below.

PC GAMER HELP!

What is -everything- I need to have a -GOOD- gaming area for a pc gamer?

Answers

Weird way to ask a question, and my reply is really late but here.

A pretty wide desk so that you have space to move around, see that beautiful pc do it's job, and to add that nice aesthetic to wherever you'd like to put it, (Preferably RGB) Mouse, and Mousepad, RGB keyboard (mechanical if you want), 144hz monitor maybe 1440p but 60hz 1080p is completely fine, you could add a normal office chair for comfort (believe me if you go cheap your back will pay the price after a long gaming session), headset/or speakers whichever you prefer (surround sound is awesome), led lights on the back of your monitor or behind your desk, and that's about all you need.

*SIMPLIFIED BUDGET FRIENDLY VERSION*

L shaped desk, monitor of choice, keyboard/mouse, led lights, and that's it. You could even add a shelf and decorate it if that matters. (I doubt anybody will even read this answer but it's ok because I like talking about electronics)

Which of the following tools helps ensure your document will open in older versions of word

Answers

Answer:

Compatibility Check

Explanation:

Select File > Info.

In the Inspect Document section, select Check for Issues > Check Compatibility.

Click Select versions to show. A check mark that appears next to the name of the mode that the document is in.

All of the following can cause a fatal execution-time error except: Group of answer choices Dereferencing a pointer that has not been initialized properly Dereferencing a null pointer Dereferencing a pointer that has not been assigned to point to a specific address Dereferencing a variable that is not a pointer

Answers

Answer: Dereferencing a variable that is not a pointer

Explanation:

The execution time also refered to as the CPU time pertaining to a given task is the time that is used by the system to execute a task.

Some of the reasons for a fatal execution-time error include:

• Dereferencing a pointer that has not been initialized properly

• Dereferencing a null pointer

• Dereferencing a pointer that has not been assigned to point to a specific address.

It should be noted that dereferencing a variable that is not a pointer doesn't cause a fatal execution-time error.

You are writing a device driver for an audio device connected to your computer. Your code needs to determine if the device is busy or ready to accept a new command. How can the driver determine this

Answers

Answer: hello the options related to your question is missing attached below is the complete question and options

answer : Read the status register ( A )

Explanation:

To determine if the device is busy or ready to accept a new command the line of action is to write a code that will Read the status register. A status register   is a hardware register which contains the information about the processor of the device ( i.e. whether the processor is busy or ready )

What is the benefit of using WYSIWYG editor

Answers

A WYSIWYG editor is a program with a rich text editing interface that allows your users to see what the end result will look like (more or less) while they're typing. Without one, users would have to edit raw HTML, which can get in the way of the writing process, to say the least.

Hope it helps! :)

Consider the efficiency of locating the kth element in a singly-linked list. How does that compare to locating the kth element in a doubly-linked list

Answers

Answer:

Finding kth element is more efficient in a doubly-linked list when compared to a singly-linked list

Explanation:

Assuming that  both lists have firs_t and last_ pointers.

For a singly-linked list ; when locating a kth element, you have iterate through a number of k-1 elements which means that locating an element will be done only in one ( 1 ) direction

For a Doubly-linked list : To locate the Kth element can be done from two ( directions ) i.e. if the Kth element can found either by traversing the number of elements before it or after it . This makes finding the Kth element faster because the shortest route can be taken.

Finding kth element is more efficient in a doubly-linked list when compared to a singly-linked list

Write a function gcd in assembly language, which takes two parameters, calculates and returns the gcd of those two numbers. You do not need to write the whole program. Just write the function part. The function should use the standard Linux registers for parameters and return values. Add additional comments to describe how you are doing the calculation.

Answers

Answer:

Explanation:

The following is written in Java. It creates the function that takes in two int values to calculate the gcd. It includes step by step comments and prints the gcd value to the console.

       public static void calculateGCD(int x, int y) {

           //x and y are the numbers to find the GCF which is needed first

           x = 12;

           y = 8;

           int gcd = 1;

           //loop through from 1 to the smallest of both numbers

           for(int i = 1; i <= x && i <= y; i++)

           {

               //returns true if both conditions are satisfied

               if(x%i==0 && y%i==0)

                   //once we have both values as true we store i as the greatest common denominator

                   gcd = i;

           }

           //prints the gcd

           System.out.printf("GCD of " + x + " and " + y + " is: " + gcd);

       }

WAP TO FIND THE PRODUCT OF 10 NATURAL NUMBERS​

Answers

Answer:

since you didn't specify which language to write it in, this is for python

Explanation:

def sum(N):

s = 0

for i in range(N + 1):

s += i

return s

def product(N):

p = 1

for i in range(1, N+1):

p *= i

return p

for i in (500, 9, -2):

print(i)

print(sum(i))

print(product(i))

Which attribute is used to specify the URL of a web page in a hyperlink?
O head
O href
O anchor
O img

Answers

Answer:

href

Explanation:

HTML is an acronym for hypertext markup language and it is a standard programming language which is used for designing, developing and creating web pages.

Generally, all HTML documents are divided into two (2) main parts; body and head. The head contains information such as version of HTML, title of a page, metadata, link to custom favicons and CSS etc. The body of the HTML document contains the contents or informations that a web page displays.

A website refers to the collective name used to describe series of web pages linked together with the same domain name while a webpage is the individual HTML document (single page) that makes up a website with a unique uniform resource locator (URL).

In Web design, the attribute which is used to specify the uniform resource locator (URL) of a web page in a hyperlink is href.

Href is an abbreviation for hypertext reference and it's typically used with the anchor tag to link to another portion of the same web page or other web page of the same website.

For example, the syntax for href is;

<a href="https://www-brainly-com">My Assignment Page </a>

Powerpoint can use existing documents of
A. Word
B. Excel
C. Access
D. All of the Above

Answers

Your answer is:



Your answer is B

real-time system needs to handle two voice calls that each run every 5 msec and consumes 1 msec of CPU time per burst, plus one video at 25 frames/sec, with each frame requiring 20 msec of CPU time. Is the system schedulable

Answers

Answer:

The explanation has follow

Explanation:

The time for a bit smaller than 1 second is one that can try if task can complete the work within second such as

Voice runs every 5 ms may be

1/0.005 that is 200 second

Similarly is a vedio run for 25 frame then it is equal to 25 time per second.

Voice that need 1 ms then it run in 200 ms per second.

Two voice task with one video = 200 ms * 2 + 500ms = 900ms

Two voice may have equall value but high then vedio. It allwoing the task to runa and need a fifo order.

Sixteen stations, numbered 1 through 16, are contending for the use of a shared channel by using the adaptive tree walk protocol. If all the stations whose addresses are prime numbers suddenly become ready at once, how many bit slots are needed to resolve the contention

Answers

Answer:

11 bit slot will be needed

Explanation:

The number of prime numbers between 1 through 16

= 2, 3 , 5, 7, 11 and 13

hence we can say 6 stations are to use the shared channel

Given that all the stations are ready simultaneously

The number of bit slots that will be needed to handle the contention will be 11 bits :

slot 1 : 2, 3, 5 , 7, 11 , 13

slot 2 : 2,3, 5, 7

slot 3 : 2, 3

slot 4 : 2 .   slot 5 : 3 .  slot 6 : 5,7.   slot 7 : 5 .   slot 8 : 7.  slot 9: 11,13.  

slot 10 : 11.   slot 11 : 13

difference between a lesson plan and scheme of work​

Answers

SORRY BUT THERE IS No difference at all

It is about that list of topics to be taught and learned for a specific period or programme, while scheme of work is drawn from the syllabus and broken into pieces to be taken on a termly basis. The lesson plan is a further breaking down of work to be done. ... Yet teachers are the key to effective learning

Which of these is true of blackhat and whitehat hackers?

Answers

Answer:

Like all hackers, black hat hackers usually have extensive knowledge about breaking into computer networks and bypassing security protocols. They are also responsible for writing malware, which is a method used to gain access to these systems.

Explanation:

that's all. c:

Answer:

c is the answer i hope help you

If the user enters any operator symbol other than , -, *, or /, then an UnknownOperatorException is thrown and the user is allowed to reenter that line of input. Define the class UnknownOperatorException as a subclass of the Exception class. Your program should also handle NumberFormatException if the user enters non-numeric data for the operand.

Answers

Answer:

Explanation:

The following code is written in Java. It creates the UnknownOperatorException class and catches it if the user enters something other than the valid operators. If so it continues asking the user for a new input. Once a valid operator is entered, it exits the function and prints the operator.

import java.util.Scanner;

class Brainly {

   public static void main(String[] args) {

       char symbol = askForOperand();

       System.out.println("Operand: " + symbol);

   }

   public static char askForOperand() {

       Scanner in = new Scanner(System.in);

       try {

           System.out.println("Enter operator symbol: ");

           char symbol = in.nextLine().charAt(0);

           if ((symbol != '-') && (symbol != '*') && (symbol != '/')) {

               System.out.println(symbol);

               throw new UnknownOperatorException();

           } else {

               return symbol;

           }

       } catch (NumberFormatException | UnknownOperatorException e) {

           System.out.println("Not a valid operand");

           char symbol = askForOperand();

           return symbol;

       }

   }

}

class UnknownOperatorException extends Exception {

   public UnknownOperatorException() {

       System.out.println("Unknown Operator");

   }

}

Other Questions
Plants contain the carbohydrates starch and cellulose. in the spring when stem growth is at its fastest rate, cellulose production rates areincreased in some plants. In the months with less sunlight, the level of starch decreases in some plants. What does this informationdemonstrate? what kind of compound is an acid? human blood types result from multiple alleles. The alleles for human blood type are written as IA, IB, and i. How many different heterozygous genotypes are possible for blood types? * a)3 b)2 c)4 d)6 The manager of the Danvers-Hilton Resort Hotel stated that the mean guest bill for a weekend is $600 or less. A member of the hotel's accounting staff noticed that the total charges for guest bills have been increasing in recent months. The accountant will use a sample of future weekend guest bills to test the manager's claim. a. Which form of the hypotheses should be used to test the manager's claim? H 0: less than or equal to $600 H a: greater than $600 b. When H 0 cannot be rejected, can we conclude that the manager's claim is wrong? No c. When H 0 can be rejected, can we conclude that the manager's claim is wrong? Yes Can some one help, step bye step please Oberon makes $13.75 an hour. He gets a 3.5% raise. What is his new hourly salary? Please help me and show working. I have a test very soon. How to solve this equation Which of the following choices is the best antonym forthe underlined word in this sentence?A freckle that is more than 1" across, has irregularsides, or is green may be a sign of an abnormal growth.Select one:A: weirdB: unhealthyC:strangeD:typicalAbnormal is the underlined word. this is only for (the brain)!!!!!!!! i will give you something that can help you reach the level you need to be on. A cable that is 45 feet long is attached to the top of a vertical pole. The cable is anchored to the ground 36 feet from the base of the pole . How tall is the pole? Round your answer to the nearest hundredth . Please help me !!!!! HELP HELP PLEASE PLEASE HELP!! GIVING BRAINIEST IF CORRECT!!!!!Out of 300 diners, 60 ordered salads. What percent of diners ordered a salad?A. 2%B. 20%C. 5%D. 15% What is the median number of TVs in Mrs. Jamison's Class? The following question has two parts. Answer Part A first, and then Part B.Part A What type of figurative language is used in the following sentence from the story?It was stuck to Jess's knee like gum to the bottom of a shoe.O idiomO simile cheO metaphorO personification Question 12SolveThe distance, s(t), in feet traveled by a freely falling object is given by the function s(t) = 162, wheret is time in seconds. Use this formula to find the time it would take for an object to fall to theground from a cliff that is 1024 feet high.7 sec64 sec8 sec9 sec What is the y-intercept 54 is 32% of what number? Round to the nearest hundredth if necessary. how does the title related to the book of dead stars? I NEED HELP FAST PLEASEEEEEEE Groups of locally trained soldiers in the American colonies were called _____.A. RedcoatsB. sons of libertyC. militias