Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -2,13 +2,13 @@ import gradio as gr
|
|
2 |
|
3 |
def calculator(text1, operation, text2):
|
4 |
if operation == "add":
|
5 |
-
return
|
6 |
elif operation == "subtract":
|
7 |
-
return
|
8 |
elif operation == "multiply":
|
9 |
-
return
|
10 |
elif operation == "divide":
|
11 |
-
return
|
12 |
|
13 |
demo = gr.Interface(
|
14 |
calculator,
|
|
|
2 |
|
3 |
def calculator(text1, operation, text2):
|
4 |
if operation == "add":
|
5 |
+
return text1 + text2
|
6 |
elif operation == "subtract":
|
7 |
+
return text1 - text2
|
8 |
elif operation == "multiply":
|
9 |
+
return text1 * text2
|
10 |
elif operation == "divide":
|
11 |
+
return text1 / text2
|
12 |
|
13 |
demo = gr.Interface(
|
14 |
calculator,
|