subject

I need help fixing my code for Syntax errors in Python. def display_larger(numberList, num):
greaterList=[]
for i in range(len(numberList)):
if numberList[i] > num:
greaterList. append(numberList[i])

return greaterList
def main():
print("\nEnter a list of 10 integers:")
numberList = []

for i in range(0, 10):
print("Enter number a number: ")
item = int(input())
numberList. append(item)

return numberList

if __name__ == "__main__":
numberList=main()
num=int(input("Enter the number you wish to test if the list elements are greater than: "))
print("Number: ",num)
print("List of numbers:\n",numberList)
newList=display_larger(numberList, num)
print("List of numbers that are larger than ",num)
print(newList)

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 20:00
What side length would you specify if you were required to create a regular hexagonal plate that was composed of 33 cm(squared) of sheet metal? dimension the side length to 0.1 cm
Answers: 2
question
Computers and Technology, 23.06.2019 07:00
What are three software programs for mobile computing?
Answers: 1
question
Computers and Technology, 23.06.2019 14:30
Select the correct answer. which step can possibly increase the severity of an incident? a. separating sensitive data from non-sensitive data b. immediately spreading the news about the incident response plan c. installing new hard disks d. increasing access controls
Answers: 2
question
Computers and Technology, 23.06.2019 16:00
Kenny works with an it company. his company is about to launch new software in the market. he has to ensure that this new software is functional and meets all of the quality standards set up at the planning stage. which job profile is kenny likely to have? kenny is likely to have the job profile of a blank .
Answers: 2
You know the right answer?
I need help fixing my code for Syntax errors in Python. def display_larger(numberList, num):
...
Questions
question
Chemistry, 25.08.2019 19:30
question
Physics, 25.08.2019 19:30
question
Mathematics, 25.08.2019 19:30