#Facebook problem using lists def facebook_time(): hours_list=[] above_4_list=[] hours=float(input("enter hours on Facebook ")) while(hours>0): hours_list.append(hours) if(hours>=4): above_4_list.append(hours) hours=float(input("enter hours on Facebook ")) print("hours list") print(hours_list) print("hours above 4 list") print(above_4_list) return sum(hours_list), len(above_4_list) def main(): total, c_above4=facebook_time() if(total==0): print("nobody used Facebook") else: print("total hours on Facebook", total) if(c_above4==0): print("nobody spent 4 hours or more") else: print(c_above4, "people spent 4 hours or more") main()