mirror of
https://github.com/TheAlgorithms/Python.git
synced 2025-07-05 01:09:40 +08:00
pyupgrade --py310-plus and run mypy in precommit, not build (#5996)
* pyupgrade --py310-plus and run mypy in precommit, not build * pyupgrade --py310-plus web_programming/fetch_well_rx_price.py * pyupgrade --py310-plus web_programming/fetch_well_rx_price.py * Fix arithmetic_analysis/in_static_equilibrium.py * Fix arithmetic_analysis/in_static_equilibrium.py
This commit is contained in:
@ -13,9 +13,9 @@ def polar_force(
|
||||
Resolves force along rectangular components.
|
||||
(force, angle) => (force_x, force_y)
|
||||
>>> polar_force(10, 45)
|
||||
[7.0710678118654755, 7.071067811865475]
|
||||
[7.071067811865477, 7.0710678118654755]
|
||||
>>> polar_force(10, 3.14, radian_mode=True)
|
||||
[-9.999987317275394, 0.01592652916486828]
|
||||
[-9.999987317275396, 0.01592652916486828]
|
||||
"""
|
||||
if radian_mode:
|
||||
return [magnitude * cos(angle), magnitude * sin(angle)]
|
||||
|
Reference in New Issue
Block a user