mirror of
https://hub.njuu.cf/TheAlgorithms/Python.git
synced 2023-10-11 13:06:12 +08:00
Rename math/add.py to maths/add.py (#1857)
* Rename math/add.py to maths/add.py * fixup! Format Python code with psf/black push * Fix sum to add * updating DIRECTORY.md Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com> Co-authored-by: John Law <johnlaw.po@gmail.com>
This commit is contained in:
parent
2fc3f2e4a0
commit
f6ee518ee1
@ -107,6 +107,7 @@
|
|||||||
* [Doubly Linked List](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/doubly_linked_list.py)
|
* [Doubly Linked List](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/doubly_linked_list.py)
|
||||||
* [From Sequence](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/from_sequence.py)
|
* [From Sequence](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/from_sequence.py)
|
||||||
* [Is Palindrome](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/is_palindrome.py)
|
* [Is Palindrome](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/is_palindrome.py)
|
||||||
|
* [Middle Element Of Linked List](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/middle_element_of_linked_list.py)
|
||||||
* [Print Reverse](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/print_reverse.py)
|
* [Print Reverse](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/print_reverse.py)
|
||||||
* [Singly Linked List](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/singly_linked_list.py)
|
* [Singly Linked List](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/singly_linked_list.py)
|
||||||
* [Skip List](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/skip_list.py)
|
* [Skip List](https://github.com/TheAlgorithms/Python/blob/master/data_structures/linked_list/skip_list.py)
|
||||||
@ -271,6 +272,7 @@
|
|||||||
* [Abs](https://github.com/TheAlgorithms/Python/blob/master/maths/abs.py)
|
* [Abs](https://github.com/TheAlgorithms/Python/blob/master/maths/abs.py)
|
||||||
* [Abs Max](https://github.com/TheAlgorithms/Python/blob/master/maths/abs_max.py)
|
* [Abs Max](https://github.com/TheAlgorithms/Python/blob/master/maths/abs_max.py)
|
||||||
* [Abs Min](https://github.com/TheAlgorithms/Python/blob/master/maths/abs_min.py)
|
* [Abs Min](https://github.com/TheAlgorithms/Python/blob/master/maths/abs_min.py)
|
||||||
|
* [Add](https://github.com/TheAlgorithms/Python/blob/master/maths/add.py)
|
||||||
* [Allocation Number](https://github.com/TheAlgorithms/Python/blob/master/maths/allocation_number.py)
|
* [Allocation Number](https://github.com/TheAlgorithms/Python/blob/master/maths/allocation_number.py)
|
||||||
* [Area Under Curve](https://github.com/TheAlgorithms/Python/blob/master/maths/area_under_curve.py)
|
* [Area Under Curve](https://github.com/TheAlgorithms/Python/blob/master/maths/area_under_curve.py)
|
||||||
* [Armstrong Numbers](https://github.com/TheAlgorithms/Python/blob/master/maths/armstrong_numbers.py)
|
* [Armstrong Numbers](https://github.com/TheAlgorithms/Python/blob/master/maths/armstrong_numbers.py)
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
"""
|
"""
|
||||||
Just to check
|
Just to check
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
|
||||||
def add(a, b):
|
def add(a, b):
|
||||||
"""
|
"""
|
||||||
>>> add(2, 2)
|
>>> add(2, 2)
|
||||||
@ -14,4 +16,4 @@ def add(a, b):
|
|||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
a = 5
|
a = 5
|
||||||
b = 6
|
b = 6
|
||||||
print(f"The sum of {a} + {b} is {sum(a, b)}")
|
print(f"The sum of {a} + {b} is {add(a, b)}")
|
Loading…
Reference in New Issue
Block a user