|
|
back to boardwrong answer python Posted by t500w 12 Oct 2016 15:57 import sys import math string = sys.stdin.read() def string_parsing(string): result = [] str = '' for j in range(len(string)): if string[j] != ' ' and string[j] != '\n': str += string[j] elif str !='': result.append(str) str = '' return result list = string_parsing(string) list = [round(math.sqrt(float(elem)), 5) for elem in list] list = ["{0:.5f}".format(elem) for elem in list] for i in range(len(list)): sys.stdout.write(str(list.pop()) + '\n') #What's wrong? Edited by author 12.10.2016 16:17 |
|
|