01 Jul Not great at this topic..
Question Description
Instructions
For this final exam, you may use the text, your notes, programs you have written, as well as PowerPoint slideshows used in class. However, this exam is designed to test your individual knowledge of the course material; Collaboration is not allowed.
You will be creating 2 programs and flow-chart for each using different constructs, functions, and data manipulation.
For each program, include the following information at the top of your code:
Your Name
Date
Final Exam – CIS126 program #
Brief statement telling the purpose of the program
EXAMPLE:
John Doe
November 5, 2017
Final Exam – CIS126 Program 1
Calculate the hypotenuse of a right triangle
For all programs, brief comments are required as follows:
All preprocessor directives
All function prototypes
All variables and arrays prototypes when defined
Description of the output from printf()
Program #1
Create a program to calculate the hypotenuse of a right triangle. The values for the sides of the triangle will be input from the keyboard; the hypotenuse will be calculated using the equation c = √(a^2+ b^2 ) where c is the length of the hypotenuse; a and b are the length of the two sides. (c is equal to the square root of the sum of a squared and b squared) (Requires the use of the SQRT() and POW() functions.
Draw the flow chart for the program.
Functional requirements
Print the header shown above before entering a loop.
Use a loop to input side a and side b, until side a is -1 (this is similar to the interest program you did earlier)
Calculate the length of the hypotenuse
Values should be output using 3 decimal place precision (hint: %3.3lf)
Program #2
Create a program with three string arrays, two 25-element arrays and one 100 element array.
Functions required:
Determine string equality
Display a message indicating the length of the string
Program execution:
Initialize the arrays in main()
Initialize the two 25-element arrays to 0
Initialize the 100-element array with: The quick brown fox jumps over the lazy dog.
Call the function to display the length of the 100-element array; use an appropriate message
Enter a string into each of the two 25-length arrays
Enter strings that match
Enter strings that do not match
Display the results with the appropriate message about comparing the two strings
Draw the flow chart for the program.
Our website has a team of professional writers who can help you write any of your homework. They will write your papers from scratch. We also have a team of editors just to make sure all papers are of HIGH QUALITY & PLAGIARISM FREE. To make an Order you only need to click Ask A Question and we will direct you to our Order Page at WriteDemy. Then fill Our Order Form with all your assignment instructions. Select your deadline and pay for your paper. You will get it few hours before your set deadline.
Fill in all the assignment paper details that are required in the order form with the standard information being the page count, deadline, academic level and type of paper. It is advisable to have this information at hand so that you can quickly fill in the necessary information needed in the form for the essay writer to be immediately assigned to your writing project. Make payment for the custom essay order to enable us to assign a suitable writer to your order. Payments are made through Paypal on a secured billing page. Finally, sit back and relax.
About Writedemy
We are a professional paper writing website. If you have searched a question and bumped into our website just know you are in the right place to get help in your coursework. We offer HIGH QUALITY & PLAGIARISM FREE Papers.
How It Works
To make an Order you only need to click on “Order Now” and we will direct you to our Order Page. Fill Our Order Form with all your assignment instructions. Select your deadline and pay for your paper. You will get it few hours before your set deadline.
Are there Discounts?
All new clients are eligible for 20% off in their first Order. Our payment method is safe and secure.