Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

USING C++ LANGUAGE ONLY. Please follow knowledge given and example output code For this homework we will observe what happens with large integer values used

USING C++ LANGUAGE ONLY. Please follow knowledge given and example output code

image text in transcribed

For this homework we will observe what happens with large integer values used in arithmetic. This C++ file implements an iterative Fibonacci algorithm. hw8.cpp Here is a Windows executable for this program: hw8.exe Run this program with the following values: F(2)=1F(5)=5 This will verify that the program works. Now try the values 40,45,46,47,48. Turn in: Write down the results for 40,45,46,47, and 48 in the textbox on Canvas. Write an explanation for the values the program returned. NO MORE THAN ONE PARAGRAPH. Shorter is better. Sample output: This program examines math with large integer values We will use an interative algoritthm to determine a Fibonacci value. You need to enter an integer, i>1 and the program will print out the ith value in the Fibonacci sequence. Please enter a positive integer greater than 1: 2 The 2th Fibonacci is: 1 Would you like to try another number ( N for no, anything else is yes): y Please enter a positive integer greater than 1: 5 The 5th Fibonacci is: 5 Would you like to try another number ( N for no, anything else is yes): y Please enter a positive integer greater than 1: 10 The 10th Fibonacci is: 55 Would you like to try another number (N for no, anything else is yes): y Please enter a positive integer greater than 1: 20 The 20th Fibonacci is: 6765 Would you like to try another number ( N for no, anything else is yes): n

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Concepts Of Database Management

Authors: Joy L. Starks, Philip J. Pratt, Mary Z. Last

9th Edition

1337093424, 978-1337093422

More Books

Students also viewed these Databases questions