menu
QAmmunity.org
Login
Register
My account
Edit my Profile
Private messages
My favorites
Register
Ask a Question
Questions
Unanswered
Tags
Categories
Ask a Question
Write an algorithm to find the maximum and minimum number from a given list of N numbers .Assume the list is not sorted
asked
Nov 2, 2018
120k
views
3
votes
Write an algorithm to find the maximum and minimum number from a given list of N numbers .Assume the list is not sorted
Computers and Technology
college
Cyber Oliveira
asked
by
Cyber Oliveira
7.9k
points
answer
comment
share this
share
0 Comments
Please
log in
or
register
to add a comment.
Please
log in
or
register
to answer this question.
1
Answer
4
votes
maxNumber = 0
minNumber = INT_MAX
for n in list:
if( n > maxNumber):
maxNumber = n
elif( n < minNumber ):
minNumber = n
Spina
answered
Nov 7, 2018
by
Spina
8.2k
points
ask related question
comment
share this
0 Comments
Please
log in
or
register
to add a comment.
Ask a Question
Welcome to QAmmunity.org, where you can ask questions and receive answers from other members of our community.
9.5m
questions
12.2m
answers
Other Questions
“What does it mean when we “rework” copyrighted material?”
Please help me ! All you do is just put it it all in your own words ! Please this is for my reported card!i don't know how to put it in my own words because my English is not that good!
describe an advance in technology that makes life more enjoyable. what discoveries contribute to this technology?
Disadvantages of using animation in advertising? advantages and disadvantages of using animation for education? advantages and disadvantages of using animation in entertainment?
Explain why binary codes are used to represent characters, numbers and symbols :)
Twitter
WhatsApp
Facebook
Reddit
LinkedIn
Email
Link Copied!
Copy
Search QAmmunity.org