Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -3,7 +3,7 @@ import gradio as gr
|
|
3 |
def func(percent, numBlocks):
|
4 |
filledSquares = "<div style='height:50px;width:50px;background-color:#555;display:inline-block'></div> "
|
5 |
emptySquares = "<div style='height:50px;width:50px;background-color:#999;display:inline-block'></div> "
|
6 |
-
numFilled = round(
|
7 |
print(f"numFilled: {numFilled}")
|
8 |
numEmpty = numBlocks - numFilled
|
9 |
print(f"numEmpty: {numEmpty}")
|
|
|
3 |
def func(percent, numBlocks):
|
4 |
filledSquares = "<div style='height:50px;width:50px;background-color:#555;display:inline-block'></div> "
|
5 |
emptySquares = "<div style='height:50px;width:50px;background-color:#999;display:inline-block'></div> "
|
6 |
+
numFilled = round((percent/100) * numBlocks)
|
7 |
print(f"numFilled: {numFilled}")
|
8 |
numEmpty = numBlocks - numFilled
|
9 |
print(f"numEmpty: {numEmpty}")
|