1
0
forked from tdwojak/Python2017
Python2017/labs05/task02.py

18 lines
341 B
Python
Raw Normal View History

2018-01-26 14:57:33 +01:00
from task00 import suma
import sys
2018-01-26 14:43:35 +01:00
def main():
2018-01-26 14:57:33 +01:00
arg_list = sys.argv[1:]
float_arg_list = []
for arg in arg_list:
2018-01-26 14:43:35 +01:00
try:
2018-01-26 14:57:33 +01:00
float_arg=float(arg)
float_arg_list.append(float_arg)
2018-01-26 14:43:35 +01:00
except:
2018-01-26 14:57:33 +01:00
float_arg_list.append(0)
print(suma(float_arg_list))
2018-01-26 14:43:35 +01:00
if __name__ == '__main__':
main()