Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

ANSWER IT WITH FULLY DETAILS PLEASE Write a program to calculate the area of any triangle with length a,b and c as shown at right.

image text in transcribed

image text in transcribed

image text in transcribed

ANSWER IT WITH FULLY DETAILS PLEASE

Write a program to calculate the area of any triangle with length a,b and c as shown at right. You can use the Heron's formula to calculate the area. The formula for area is shown: A=s(sa)(sb)(sc) And value of s is half the perimeter of the triangle. s=2a+b+c The values for sides a,b and c should be read from the keyboard. Use the Math.sqrt() method for calculating the square root. If values of a is 3.0 and b is 4.0 and c os 5.0 then the output (displayed to 3 decimal places) should be: The area of the triangle is: 6.000 But before write the code, write down your algorithm. HOW to SUBMIT WORK? Same Word file for Question 2. Move to a new page and put a label heading for Question 3at top followed by: ( 4 points for (a), 13 points for (b) and 3 points for (c)) a. Your algorithm of what to do b. Your Java source code that will implement your algorithm in step (a) above. c. Screenshot of outputs and inputs. Make sure to follow appropriate Java coding style when writing your code. Write a program that converts a temperature from Celsius to Fahrenheit. It should (1) prompt the user for input, (2) read a double value from the keyboard, (3) calculate the result, and (4) format the output to one decimal place. For example, if input for Celsius is 24.0 then the output should be like this: 24.0 Celsius =75.2 Fahrenheit. Here is the formula (where F is Fahrenheit and C for Celsius) F=C59+32 Be careful not to use integer division! First, write your algorithm and remember to use meaningful names for your variables instead of F and C. HOW to SUBMIT WORK? A Word file with a label heading for Question 1 at top followed by: (4 points for (a), 13 points for (b) and 3 points for (c)) a. Your algorithm of what to do b. Your Java source code that will implement your algorithm in step (a) above

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

Visual Basic6 Database Programming

Authors: John W. Fronckowiak, David J. Helda

1st Edition

ISBN: 0764532545, 978-0764532542

More Books

Students also viewed these Databases questions

Question

Describe the job youd like to be doing five years from now.

Answered: 1 week ago

Question

So what disadvantages have you witnessed? (specific)

Answered: 1 week ago