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]
3 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]3 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
Yasmin arrived home from play practice at 4:25 p.M the walk home took 15 minutes practice began 20 minutes after the final bell
anygoal [31]

Answer:

3:20

Step-by-step explanation:

4:25-15= 4:10

4:10-20=3:50

3:50-30=3:20

School ended at 3:20

6 0
3 years ago
A camera has a listed price of $658.95 before tax. If the sales tax rate is 9.75%, find the total cost of the camera with sales
jeka57 [31]

Answer:

$721.55

Step-by-step explanation:

658.95*1.095=721.55

4 0
3 years ago
Approximately how many people make between $30,000 and $66,000​
Alja [10]

Answer:

approximately 1 to 7.674 billion people

Step-by-step explanation:

cause theres 7.674 billion peepsin the world

8 0
3 years ago
HELP ASAP How many times will the digit '3' appear if we write all whole numbers from 1 to 99?
Liula [17]

Answer:3,13,23,30,31,32,33,34,35,36,37,38,39,43,53,63,73,83,93

Step-by-step explanation:

You gotta count I did this quick

8 0
3 years ago
Read 2 more answers
(1) [6pts] Let R be the relation {(0, 1), (1, 1), (1, 2), (2, 0), (2, 2), (3, 0)} defined on the set {0, 1, 2, 3}. Find the foll
goldenfox [79]

Answer:

Following are the solution to the given points:

Step-by-step explanation:

In point 1:

The Reflexive closure:  

Relationship R reflexive closure becomes achieved with both the addition(a,a) to R Therefore, (a,a) is  (0,0),(1,1),(2,2) \ and \ (3,3)

Thus, the reflexive closure: R={(0,0),(0,1),(1,1),(1,2),(2,0),(2,2),(3,0), (3,3)}

In point 2:

The Symmetric closure:

R relation symmetrically closes by adding(b,a) to R for each (a,b) of R  Therefore, here (b,a) is:   (0,1),(0,2)\ and \ (0,3)

Thus, the Symmetrical closure:

R={(0,1),(0,2),(0,3)(1,0),(1,1)(1,2),(2,0),(2,2),(3,0), (3,3)}

8 0
3 years ago
Other questions:
  • Three other samples were taken using the same confidence
    10·1 answer
  • 5<img src="https://tex.z-dn.net/?f=%20%5E2x%20%3D625%3Cbr%3E%0A" id="TexFormula1" title=" ^2x =625&amp;#10;" alt=" ^2x =625&amp;
    9·1 answer
  • El cuadrado de un número menos 5 es igual a 220. ¿Cuál es ese número?
    10·2 answers
  • amy has 72 Street and affection keeps one fourth of them for herself and she read the rest of their friends how many sweets will
    14·1 answer
  • Janice bought 40 shares of stock at $31.82 per share. She received dividends of $1.11 per share for 1 year. What was her purchas
    5·2 answers
  • NEED HELP. For an absolute value equation, there are two solutions. Use the given equation and its solutions to algebraically pr
    12·1 answer
  • Facorts of 8 pleaseeeeeeeeeeeeeeeeeeeeee
    9·2 answers
  • A total of 46 students signed up to play in a flag football league if each team has 10 students how many more students will need
    7·1 answer
  • PLZ HELP ME OUT WITH THIS!!!!!!!!
    15·1 answer
  • What is t? <br> 12t - 8t = -52
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!