mirror of
https://github.com/TheAlgorithms/Python.git
synced 2026-03-13 09:50:19 +08:00
Enable ruff SIM102 rule (#11341)
* Enable ruff SIM102 rule * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Fix * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
@@ -37,11 +37,14 @@ def calculate_waitingtime(
|
||||
# Process until all processes are completed
|
||||
while complete != no_of_processes:
|
||||
for j in range(no_of_processes):
|
||||
if arrival_time[j] <= increment_time and remaining_time[j] > 0:
|
||||
if remaining_time[j] < minm:
|
||||
minm = remaining_time[j]
|
||||
short = j
|
||||
check = True
|
||||
if (
|
||||
arrival_time[j] <= increment_time
|
||||
and remaining_time[j] > 0
|
||||
and remaining_time[j] < minm
|
||||
):
|
||||
minm = remaining_time[j]
|
||||
short = j
|
||||
check = True
|
||||
|
||||
if not check:
|
||||
increment_time += 1
|
||||
|
||||
Reference in New Issue
Block a user