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
Softa [21]
2 years ago
11

Give a recursive algorithm which takes as input a sequence of numbers and returns the minimum (i.e., smallest) number in the seq

uence. Your algorithm should not use a loop.
Mathematics
1 answer:
kodGreya [7K]2 years ago
5 0

Answer:

Step-by-step explanation:

So let a[i] be the input array to the function find_minimum(): . We will use python to present this recursive algorithm

def find_minimum(a, n):

    if n == 1:

         return a[0]

    return min(a[n], find_minimum(a, n - 1))

find_minimum(a, len(a) - 1)

You might be interested in
Use the given graph to determine the limit, if it exists.
Georgia [21]
The limit is - 1.
_____
5 0
3 years ago
Read 2 more answers
Evaluate f(-3) and f(5) with the equation f(x)=3x+5
OLga [1]
See photos for solutions and steps :)

4 0
3 years ago
Read 2 more answers
BIG COW LITTLE COW FAT COW ADORABLE COW
alexandr1967 [171]
Ahh that’s very very very very swag
4 0
2 years ago
Read 2 more answers
What is x + 9≤10 as an inequalite ?
Novosadov [1.4K]
X is less then or equal to 1<u /><em /><u />
4 0
3 years ago
Read 2 more answers
Which expression should appear in Line 2?
kipiarov [429]

Answer:

c.

............

..............................

8 0
2 years ago
Other questions:
  • I need help on these two problems
    10·1 answer
  • Which term describes the variable y in the expression y over n
    5·1 answer
  • 8.4×3.7 please show your work
    11·2 answers
  • Evaluate the expression for a = 5, b = 11, and c = 3. 2a + 2c(b − 5) A. 64 B. 46 C. 54 D. 163
    13·1 answer
  • _ +18=5+41<br><br> What is the equation to finding the missing number
    9·2 answers
  • I just wrote a formal email to my teacher. What do you think their response was?
    10·2 answers
  • Can sombody please help me?!​
    13·1 answer
  • 4)
    6·1 answer
  • Solve for x:<br> 4(1 – x) + 2 x = -3( x + 1)
    6·2 answers
  • Select the correct answer from each drop-down menu.
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!