Skip to content

Commit 68b58c9

Browse files
committed
fix pep
1 parent 7ede1bb commit 68b58c9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

final_task/pycalc/calc.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ def calc_iteration(expression):
271271
stack.append(a ** b)
272272
else:
273273
stack.append(i)
274-
expression.remove((i))
274+
expression.remove(i)
275275
if i in ops_list:
276276
arg = []
277277
ops, arg0 = get_arguments(expression)
@@ -332,8 +332,8 @@ def to_postfix(expression):
332332
ops_bracket.pop()
333333
res.append(i)
334334
elif i in binary_operations:
335-
if stack and stack[-1] in binary_operations and binary_operations[stack[-1]] >= binary_operations[
336-
i] and i != '^':
335+
if stack and stack[-1] in binary_operations and \
336+
binary_operations[stack[-1]] >= binary_operations[i] and i != '^':
337337
while stack and stack[-1] in binary_operations and binary_operations[stack[-1]] >= binary_operations[i]:
338338
res.append(stack.pop())
339339
stack.append(i)

0 commit comments

Comments
 (0)