ComputerScienceExpert

(11)

$18/per page/

About ComputerScienceExpert

Levels Tought:
Elementary,Middle School,High School,College,University,PHD

Expertise:
Applied Sciences,Calculus See all
Applied Sciences,Calculus,Chemistry,Computer Science,Environmental science,Information Systems,Science Hide all
Teaching Since: Apr 2017
Last Sign in: 103 Weeks Ago, 4 Days Ago
Questions Answered: 4870
Tutorials Posted: 4863

Education

  • MBA IT, Mater in Science and Technology
    Devry
    Jul-1996 - Jul-2000

Experience

  • Professor
    Devry University
    Mar-2010 - Oct-2016

Category > Programming Posted 27 Apr 2017 My Price 8.00

deals with a range-based for loop

Hi, I have a project for CISS 110 that I need some help. I will submit this tomorrow. I attached the specifics. Thank you.


This project deals with a range-based for loop where we know the exact number of
times a loop will iterate (perform the associated block of code). You will also use
an if/else construct to determine if work will be done based on the values entered by
the user. In addition, we are using the static methods from the Math class,
namely pow() and sqrt().
Given:
int x, lowerBound, upperBound;
double square, squareRoot; Have the user enter a lower bound and an upper bound for a range of integers.
If lowerBound is greater than the upperBound, inform the user that no work will be
performed otherwise you will construct a for loop to process the range of values from
the lower bound to the upper bound, inclusive, incrementing by one each time.
Each time through the loop, using the pow() and sqrt() static Math methods, calculate
the square and square root of each value and store the result in the appropriate
variable. Display your results. All results involving precision should be to two decimal
places using the printf() method of System.out.

Attachments:

Answers

(11)
Status NEW Posted 27 Apr 2017 03:04 AM My Price 8.00

-----------

Not Rated(0)