Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
This repository was archived by the owner on Jun 23, 2025. It is now read-only.

Commit d2bfb10

Browse filesBrowse files
authored
style: include LII_LIST_INDEXED_ITERATING (TheAlgorithms#5190)
1 parent 2cda944 commit d2bfb10
Copy full SHA for d2bfb10

File tree

Expand file treeCollapse file tree

3 files changed

+5
-6
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

3 files changed

+5
-6
lines changed
Open diff view settings
Collapse file

‎spotbugs-exclude.xml‎

Copy file name to clipboardExpand all lines: spotbugs-exclude.xml
-3Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,6 @@
141141
<Match>
142142
<Bug pattern="TR_TAIL_RECURSION" />
143143
</Match>
144-
<Match>
145-
<Bug pattern="LII_LIST_INDEXED_ITERATING" />
146-
</Match>
147144
<Match>
148145
<Bug pattern="USBR_UNNECESSARY_STORE_BEFORE_RETURN" />
149146
</Match>
Collapse file

‎src/main/java/com/thealgorithms/scheduling/FCFSScheduling.java‎

Copy file name to clipboardExpand all lines: src/main/java/com/thealgorithms/scheduling/FCFSScheduling.java
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ private void evaluateWaitingTime() {
4040
}
4141

4242
private void evaluateTurnAroundTime() {
43-
for (int i = 0; i < processes.size(); i++) {
44-
processes.get(i).setTurnAroundTimeTime(processes.get(i).getBurstTime() + processes.get(i).getWaitingTime());
43+
for (final var process : processes) {
44+
process.setTurnAroundTimeTime(process.getBurstTime() + process.getWaitingTime());
4545
}
4646
}
4747
}
Collapse file

‎src/main/java/com/thealgorithms/scheduling/RRScheduling.java‎

Copy file name to clipboardExpand all lines: src/main/java/com/thealgorithms/scheduling/RRScheduling.java
+3-1Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,8 @@ private void evaluateTurnAroundTime() {
9595
}
9696

9797
private void evaluateWaitingTime() {
98-
for (int i = 0; i < processes.size(); i++) processes.get(i).setWaitingTime(processes.get(i).getTurnAroundTimeTime() - processes.get(i).getBurstTime());
98+
for (final var process : processes) {
99+
process.setWaitingTime(process.getTurnAroundTimeTime() - process.getBurstTime());
100+
}
99101
}
100102
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.