1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Margaret [11]
4 years ago
9

The function below takes a single parameter number_list which is a list that can contain integers and floats. Complete the funct

ion to return the integer from the provided list that is the largest. There are two recommended approaches for this function. You could either filter out just the integers and use Python's built-in max function, or you could use the find best pattern and only consider list elements that are integers as potentially being the best.
Computers and Technology
1 answer:
Andreas93 [3]4 years ago
6 0

Answer:

  1. def getLargest(number_list):
  2.    new_list = []
  3.    for x in number_list:
  4.        if(isinstance(x, int)):
  5.            new_list.append(x)
  6.    largest = max(new_list)
  7.    return largest  

Explanation:

Firstly, create a function <em>getLargest()</em> that take one input parameter, <em>number_list</em>.

The function will filter out the float type number from the list by using <em>isinstance() </em>method (Line 5). This method will check if a current x value is an integer. If so, the x value will be added to <em>new_list</em>.

Next, use Python built-in <em>max</em> function to get the largest integer from the <em>new_list </em>and return it as output.

You might be interested in
Self-contained sequences of actions to be performed are: (1 point)
beks73 [17]
These are functions.
6 0
3 years ago
Read 2 more answers
Universal Containers sells its products online using a system built on Force Sites. The orders are captured and processed in Sal
sveta [45]

Answer:

Use Outbound Messages to send customer data from Salesforce to the marketing system.

Use a middleware tool to pull customer data from Salesforce and push it to the marketing system on a daily basis

Use Apex callout to send customer data from Salesforce to the marketing system

Explanation:

The above points illustrates a mechanism for moving cutomer data to the marketing system efficiently.

3 0
4 years ago
Why is it a good idea to only use one word for everything you create in Scratch, even though you can technically use two words f
Keith_Richards [23]

Answer:So if your in a situation where you need 1 of those words then your strategy would come in handy.

Explanation:

7 0
2 years ago
How many centimeters are there in 1 meters
konstantin123 [22]
1 meters is = 100 centimeters
8 0
4 years ago
Read 2 more answers
You have double-clicked a device in Device Manager to open its Properties window. Where can you find information about IRQs the
Setler [38]

To find information about IRQs the device might use, make alteration to the View menu option and then change it to Resources by type.

<h3>How do one find information about IRQs?</h3>

The best way to see IRQ information in Windows is through the use of Device Manager.

Note that for one to be able to find information about IRQs the device might use, one has to makes some changes to the View menu option and then one can change it to Resources by type to be able to see the Interrupt request (IRQ) part.

Learn more about Device Manager from

brainly.com/question/869693

#SJ1

7 0
2 years ago
Other questions:
  • A custom date format set for a date/time field that contains the symbols mmm/dd/yy would display the date as ____.
    12·1 answer
  • Which business application uses location information to provide a service and is designed to give mobile users instant access to
    5·1 answer
  • For any element in keysList with a value smaller than 40, print the corresponding value in itemsList, followed by a space.
    6·1 answer
  • Below is an image from Google Trends that plots Cats and Dogs. It shows a line that is higher for dogs than cats. Choose the mos
    11·1 answer
  • Sadie helman runs a web site for amateur snowboarders. she likes to post videos and music related to snowboarding on her site as
    12·1 answer
  • Jemima is reviewing her history report and notices that her headings are not formatted the same throughout the
    7·1 answer
  • Python: initalize the variable first_name with the value from the user prompt "What is your first name? " initalize the variable
    9·1 answer
  • Before posting a picture online, make sure to
    7·1 answer
  • State differences between title bar and menu bar​
    5·1 answer
  • How do you get a blank business card template in word?
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!