Commit 410d0f89 by BellCodeEditor

auto save

parent b6f707f7
Showing with 20 additions and 0 deletions
with open("num.txt","r",encoding="utf-8") as file1:
a = file1.readlines()
for i in a:
data = i.split()
name = data[0]
number = data[1:]
sum = 0
for money in number:
sum += int(money)
result = sum
print(data[0]+str(result))
\ No newline at end of file
def circle(r,h):
mc = (2*3.14*float(r))*(2*3.14*float(r))
vc = mc * float(h)
print(vc)
return(vc)
circle(2,2)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment