Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Shavit Borisov
- // HW
- import java.util.Scanner;
- public class DaysToWeeks {
- public static void main(String[] args)
- {
- Scanner in = new Scanner (System.in);
- System.out.println("Enter the number of days:");
- int days = in.nextInt();
- int weeks = days/7;
- System.out.printf("The number of weeks is %d.", weeks);
- in.close();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment