Answer to Question #239000 in Java | JSP | JSF for Woyengimiesindo Ma

Question #239000
How cold is it outside? The temperature alone is not enough to provide the answer. Other factors including wind speed, relative
humidity, and sunshine play important roles in determining coldness outside. In 2001, the National Weather Service (NWS)
implemented the new wind-chill temperature to measure the coldness using temperature and wind speed. The formula is
twc = 35.74 + 0.6215ta - 35.75v0.16 + 0.4275tav
0.16
where ta is the outside temperature measured in degrees Fahrenheit and v is the speed measured in miles per hour. twc is the
wind-chill temperature. The formula cannot be used for wind speeds below 2 mph or temperatures below -58
1
Expert's answer
2021-09-20T07:48:10-0400
import java.util.Scanner;
public class Main
{
	public static void main(String[] args){
		double ta,v,x,y,z,m,n;
		System.out.print("Enter the temperature in Ferverent between -58F and 41F: ");
		Scanner input =new Scanner (System.in);
		ta=input.nextInt();
		System.out.print("Enter the wind speed(>=2) in miles per hour: ");
		v=input.nextInt();
		x=35.74+0.621*ta;
		double base = 35.75, exponent = 0.16;
        y = Math.pow(base, exponent);
		z=Math.pow((0.4275*ta*v),0.16);
		m=y+z;
		n=x-z;
		System.out.print("The wind chill index is: ");
		System.out.print(n);
	}
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS