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
Charra [1.4K]
2 years ago
6

Fill in the code to complete the following function for computing a Fibonacci number. public static int fib(int index) { if (ind

ex == 0 || index == 1) // Base case ________ else // Reduction and recursive calls return fib(index - 1) + fib(index - 2); }
Mathematics
1 answer:
Lubov Fominskaja [6]2 years ago
6 0

Answer:

return 0;

Step-by-step explanation:

The  Fibonacci numbers such that each number is the sum of the two preceding ones, but the first therm of the sequence cannot be built by this rule.

In that F_{0} = 0

Then you may define it in the base case

return 0;

You might be interested in
PLS HELP ME ASAP FOR 27!! (MUST SHOW WORK!!) *maybe use a picture to draw it* + LOTS OF POINTS!!
adell [148]
The answer is 1 cause 1/2 times 2 sides. Just draw a square with side lengths of 1/2
3 0
3 years ago
BRAINLIEST!! Pleaseee help me this is urgent
mojhsa [17]

Answer:

190        195

-------  =  -------

50           z

Solve for z:

1. Cross multiply

190z = (50)(195)

190z / 190 = 9750 / 190

z ≈ 51.3

5 0
3 years ago
The octal system uses base 8. the only available digits would be 0, 1, 2, 3, 4, 5, 6, and 7. if the value 2468 is converted to d
marysya [2.9K]
Your description and expansion suggest you want to evaluate
.. 246₈ = 2*8² +4*8¹ +6*8⁰
.. = 2*64 +4*8 +6
.. = 166
5 0
3 years ago
Alesha went to the movies. A popcorn is $3 more than a soda. She purchased 1 popcorn and 2 sodas. She spent $21. How much is a p
Blizzard [7]

Answer: a popcorn is $9

Step-by-step explanation:

soda is $6

8 0
1 year ago
Note: Images may not be drawn to scale
OleMash [197]

Answer:

  1/3

Step-by-step explanation:

The scale factor is the ratio of image lengths to original lengths. For this pair of figures, the scale factor is ...

  A'B'/AB = 2/6 = 1/3

The scale factor is 1/3.

8 0
2 years ago
Other questions:
  • Order the numbers 0.64, 2/3 , 65%, and 7/10 from least to greatest.
    12·2 answers
  • ANSWER ASAP (17 points)
    6·2 answers
  • Help me again, please. ;w;
    9·1 answer
  • A group of friends ordered a large pizza. The pizza they ordered has 10 slices. If each friend gets 1 1/3 slice of pizza, how ma
    8·2 answers
  • What is the gross annual pay for Saul if he works 40 hours each week but also works 4 hours of overtime every two weeks? (Saul m
    9·2 answers
  • What is the radius?
    5·1 answer
  • A soccer field is a rectangle 90 meters wide and 120 meters long. The coach asks the players to run from one corner to the corne
    5·1 answer
  • Lamar earns 40% of her daily earnings moving furniture if she earns $150 in total on one day how much money did she earn moving
    7·1 answer
  • Henry is 7 years older than his brother,ted.the sum of their ages is 23 years how old is each
    11·2 answers
  • What does x equals (x+16)
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!