Skip to content
This repository was archived by the owner on Nov 4, 2024. It is now read-only.

Commit a37d96b

Browse files
Update pivot_index_array.py
1 parent a4fe8d5 commit a37d96b

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

arrays_and_strings/pivot_index_array.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,9 @@
33
# author: bt3gl
44

55

6-
def pivotIndex(nums):
6+
def pivot_index(nums):
77

8-
s = sum(nums)
9-
10-
left_sum = 0
8+
s, left_sum = sum(nums), 0
119

1210
for i, x in enumerate(nums):
1311

0 commit comments

Comments
 (0)