Question: Write an assembly program that, given two consecutive members of the Fibonacci sequence, computes the three following members. The Fibonacci sequence is given by the

Write an assembly program that, given two consecutive members of the Fibonacci sequence, computes the three following members. The Fibonacci sequence is given by the sequence
123581321...
where every number, starting with 3, is the sum of the preceding two numbers. For example,
3=1+2
5=2+3
21=8+13
You can assume that the starting numbers n1 and n2 of type DCD are initialized in the CODE area. For example, n1 DCD 3, n2 DCD 5. In this case the output should be 81321. Your code should work for any two given numbers and output the computed three numbers to the screen.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!