Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package cool;
- import java.util.Scanner;
- public class wool {
- public static void main(String[] args) {
- //круг по радиусу
- Scanner scan = new Scanner(System.in);
- System.out.println("Введите радиус");
- double cm = scan.nextDouble();
- System.out.println("Окружность равна "+cm*6.28 );
- //секунды в нормальное время
- Scanner scan = new Scanner(System.in);
- System.out.println("Введите секунды");
- int sec = scan.nextInt();
- int hours = sec/3600;
- int minutes = (sec-hours*3600)/60;
- int seconds = sec-hours*3600-minutes*60;
- System.out.println(hours+";"+minutes+";"+seconds );
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement