<u><em>[ Absolute ]</em></u><em> Addresses do not change if you copy them to a different cell.</em>
<u><em>[ Relative ]</em></u><em> </em><em>Addresses change depending on the cells you copy them to.</em>
Answer:
The answer is A
Explanation:
Basically, Shortest job first (SJF) is a scheduling policy that selects jobs on queue for execution within a short execution time.
From the definition of SJF above, it means that there are a lot of process on queue and the (SJF) job is to receive processes on queue to execute within a short execution time.
Therefore, if all the jobs or process arrives at the SJF at the same time, the SJF will forfeit one of its major purpose which is scheduling of jobs.
That will therefore not make Non-preemptive Shortest Job First (SJF) not function at its optimal point.
Answer:
- import java.util.Arrays;
- import java.util.Scanner;
-
- public class Main {
- public static void main(String[] args) {
- Scanner input = new Scanner(System.in);
- double distances [] = new double[7];
-
- for(int i=0; i < distances.length; i++){
- System.out.print("Input running distance for day " + (i+1) + ": ");
- distances[i] = input.nextDouble();
- }
-
- System.out.println(Arrays.toString(distances));
- }
- }
Explanation:
The solution code is written in Java.
Firstly, create a Scanner object to get user input for running distance (Line 6). Next, declare a distances array and set the array size to 7 because we intend to use this array to hold running distance for 7 days per week.
Next, use the for loop that run for 7 times to repeatedly prompt user to input running distance for each day and store each value to the array distances (Line 9 -12).
At last, display the array to console terminal (Line 14).
A device connected to the internet is known as a Node.