Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class CelsiusToFahrenheit {
- public static void main(String[] args) {
- Scanner scanner = new Scanner(System.in);
- double celsius = Double.parseDouble(scanner.nextLine());
- double fahrenheit = celsius * 1.800 + 32;
- System.out.printf("%.2f", fahrenheit);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement