Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Java (1) Prompt the user to input a character and real number, and output them. (1 pts) Enter a character: Enter a number: 5.2 The

Java

image text in transcribed

(1) Prompt the user to input a character and real number, and output them. (1 pts) Enter a character: Enter a number: 5.2 The inputs are A and 5.2 (2) if the character is A and the number is positive, calculate the area of a circle using the number as the radius, format to 2 decimal places (3 pts) Area with radius 5.2 is 84.95 (2) if the character is 'C' and the number is positive, calculate the circumference of a circle using the number as the radius, format to 2 decimal places (3 pts) Circumference with radius 5.2 is 32.67 (3) if the character is not 'A' or 'C', or the number is not positive, print error message (3 pts) Invalid entry

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

Oracle 10g Database Administrator Implementation And Administration

Authors: Gavin Powell, Carol McCullough Dieter

2nd Edition

1418836656, 9781418836658

More Books

Students also viewed these Databases questions

Question

Explain how a supervisor can use feedback to improve communication.

Answered: 1 week ago

Question

=+j Explain the relationship between unions and MNEs.

Answered: 1 week ago

Question

=+Have they changed the way employees view IP?

Answered: 1 week ago