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
photoshop1234 [79]
3 years ago
11

Define the function max2 that takes two integers as arguments and returns the largest of them. Then define the function max_list t

hat returns the largest of the elements in a nonempty list of integers by calling max2
Computers and Technology
1 answer:
Serga [27]3 years ago
6 0

Answer:

def max_list(a):

   return max(a)

def max2(a,b):

   return max(a,b)

s=max2(2,3)

print('max of two number is:')

print(s)

a=[1,2,3,4,5,6,7,8,9,10]

max_in_list = max_list(a)

print('\n max element in whole list is:')

print(max_in_list)

Explanation:

Above program is written in python:

Function max2 accept two parameters and return one which is greatest of both and funtion max_list accept a parameter list and returns the greatest number in list.

Note: take care of indentation of function while pasting this code on your compiler or ide

You might be interested in
Which pair of devices have the same input motion and different outputs?
allochka39001 [22]

Answer:

nutcracker and can opener

Explanation:

5 0
3 years ago
What does CS mean? idk
Rainbow [258]
Computer science or computer software
3 0
2 years ago
Read 2 more answers
What is an analog computer?<br>​
tigry1 [53]

Answer:

It is a computer that is used to process analog data.

7 0
3 years ago
Read 2 more answers
Which slide elements must claire use to enhance her presentation?
Crank

The answer for the 1st blank is text.


6 0
3 years ago
Read 2 more answers
You can access various sites on WWW by using hyperlinks or by?
wlad13 [49]
You can access various sites on WWW by using hyperlinks or by?

Answer is: A following directions on-screen
5 0
2 years ago
Read 2 more answers
Other questions:
  • The technology (software) that automatically downloads website information to your computer is called ________.'
    15·1 answer
  • "Suppose that instead of always selecting the first activity to finish, we instead select the last activity to start that is com
    14·1 answer
  • The Sumif formula will add numbers together from a range of numbers ONLY IF they contain the criteria. True or false
    8·1 answer
  • While inserting images, the Picture command is usually used to insert photos from a digital camera, and the Clip Art command is
    7·1 answer
  • In order to make burger a chef needs the following ingredients one piece of chicken meat 3 lettuce leaves 6 tomato slices Write
    8·1 answer
  • Someone help ASAP! Match the type of information system with its description.
    13·2 answers
  • Which do switches create?<br> Networks<br> Wireless access points<br> Routes<br> Collision domains
    13·1 answer
  • BEING TIMED HELP ASAP
    12·2 answers
  • What makes a source credible?
    9·2 answers
  • A photographer stores digital photographs on her computer. In this case the photographs are considered the data. Each photograph
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!