Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion checkstyle.xml
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@
<module name="EmptyForIteratorPad"/>
<!-- TODO <module name="GenericWhitespace"/> -->
<module name="MethodParamPad"/>
<!-- TODO <module name="NoWhitespaceAfter"/> -->
<module name="NoWhitespaceAfter"/>
<module name="NoWhitespaceBefore"/>
<module name="OperatorWrap"/>
<module name="ParenPad"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ private static int[] initializeColors(int numberOfVertices) {
}

private static Integer[] getSortedNodes(final Graph graph) {
return IntStream.range(0, graph.getNumVertices()).boxed().sorted(Comparator.comparingInt(v -> - graph.getAdjacencyList(v).size())).toArray(Integer[] ::new);
return IntStream.range(0, graph.getNumVertices()).boxed().sorted(Comparator.comparingInt(v -> -graph.getAdjacencyList(v).size())).toArray(Integer[] ::new);
}

private static boolean[] computeUsedColors(final Graph graph, final int vertex, final int[] colors) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ private PreemptivePriorityScheduling() {
}
public static List<String> preemptivePriorityScheduling(List<Process> processes) {
List<String> ganttChart = new ArrayList<>();
PriorityQueue<Process> readyQueue = new PriorityQueue<>(Comparator.comparingInt(p -> - p.priority));
PriorityQueue<Process> readyQueue = new PriorityQueue<>(Comparator.comparingInt(p -> -p.priority));

int currentTime = 0;

Expand Down
Loading