Optimized recursive_bubble_sort (#2410)
* optimized recursive_bubble_sort
* Fixed doctest error due whitespace
* reduce loop times for optimization
* fixup! Format Python code with psf/black push
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
This commit is contained in:
@@ -9,7 +9,7 @@ from sympy import diff
|
||||
|
||||
|
||||
def newton_raphson(func: str, a: int, precision: int = 10 ** -10) -> float:
|
||||
""" Finds root from the point 'a' onwards by Newton-Raphson method
|
||||
"""Finds root from the point 'a' onwards by Newton-Raphson method
|
||||
>>> newton_raphson("sin(x)", 2)
|
||||
3.1415926536808043
|
||||
>>> newton_raphson("x**2 - 5*x +2", 0.4)
|
||||
|
||||
Reference in New Issue
Block a user