Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -18,7 +18,12 @@ def dumb_calculator(arg1:int, arg2:int)-> float: #it's import to specify the ret
|
|
18 |
arg2 (int): the second argument
|
19 |
"""
|
20 |
import numpy as np
|
21 |
-
|
|
|
|
|
|
|
|
|
|
|
22 |
|
23 |
@tool
|
24 |
def get_current_time_in_timezone(timezone: str) -> str:
|
|
|
18 |
arg2 (int): the second argument
|
19 |
"""
|
20 |
import numpy as np
|
21 |
+
if str(int(arg1) == 0) and str(int(arg2) == 0):
|
22 |
+
return f"All values are equal to 0. The results is {0}."
|
23 |
+
elif str(int(arg1) != 0) and str(int(arg2) != 0):
|
24 |
+
return f"Both values are different. We multiply. The result is {arg1 * arg2}."
|
25 |
+
else:
|
26 |
+
return f"One of the values is 0. We square the sum of {arg1} and {arg2}. The result is {np.sqrt(arg1 + arg2)}."
|
27 |
|
28 |
@tool
|
29 |
def get_current_time_in_timezone(timezone: str) -> str:
|