Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Using PYTHON, I need to convert my timeList in seconds to h,m,s. What code do I

ID: 3781524 • Letter: U

Question

Using PYTHON, I need to convert my timeList in seconds to h,m,s. What code do I need to convert correctly using my code listed?

My code is as follows:

import statistics

def parse():
a=input("Please enter a data center letter: ")
a=a.lower()
dc="dc="+a
numList=[]
timeList=[]
file=open("data.Data.txt","r")
lines=file.readlines()
file.close()
for line in lines:
wordList=line.lower().split()
number=wordList[2]
time=wordList[1]
if (dc in wordList):
numList.append(number)
timeList.append(time)
#print("DC=A",wordList)
numList=[float(i) for i in numList]
avg=statistics.mean(numList)
#numList.sort()
#print (timeList)
#print (numList)
res2=statistics.median(numList)
outliers=outlier(numList,timeList,avg)
print("Average= ",avg)
print ("Median= ", res2)
'''print (outliers)'''
return

def mean(aList):
return float(sum(aList)) / max(len(aList), 1)
  
def outlier(numList,timeList,avg):
outliers={}
for each in numList:
t=timeList[numList.index(each)]
if (each < avg/3):
outliers[t]=each
print("OUTLIER(-): " ,t,"|",each)
'''figure this out'''
if(each > avg*3):
outliers[t]= each
print("OUTLIER(+): " ,t, "|",each)
return outliers

Data.txt location https://drive.google.com/open?id=0B-rrZhXoU7AaZEd3Ymw1SWY5S3M

import statistics def parse() input ("Please enter a data center letter a a lower dc. num List time List file open data do txt "r") file close for line lines line lower split number wordList [2] time wordList. [1] if (dc in word List) numList. append (number) time List. append (time) print ("DC-A Word List) num List [float (i) for i in numList] avg statistics mean (numList) #numList. Sort print (time List) print (numList) res2 statistics. median (numList) outliers outlier (numList, timeList, avg) print "Average avg) print ("Median res2) print (outliers) T 1 1 return def mean (aList) return float (sum (aList) max (len (aList), 1) def outlier (numList, timeList, avg) outliers for each in numList t time List [numL ist. index (each) if (each avg/3) outliers [t] each print ("OUTLIER ,t, l each) figure this out' if (each avg*3) outliers [t] each print ("OUT LIER t, l n,e each) return outliers

Explanation / Answer

There are few questions regarding the given question

What is the value of 'Data center letter' ?

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote