Question: Java please. Write a program SelectWinner.java to pick winners. You have 4 t-shirts and 2 ipads to give away and a pool of 16 students.
Write a program SelectWinner.java to pick winners. You have 4 t-shirts and 2 ipads to give away and a pool of 16 students. The students are assigned numbers from 1 to 16. (Make use of loops in your program). a. Randomly select 4 students to receive the t-shirts. (It is OK to select the same student more than one time) b. Randomly select 2 students to receive the iPads. Make sure to pick two different students. Sample output: Winners for T-shirts are: Student number 7 9 12 9 Winners for i-Pads are: Student number 5 12 Write a program Days.java that performs the following Define a method called getDays which takes three integer parameters, month, day and year of a date, calculate and return the day number (total number of days since Jan 1^st) of the year. (Should consider leap year, make use of loops and do not use built-in Calendar class) Take user input of month, day and year of a date, call getDays method to print the date with full month name and day number of the year. See sample output. Sample output1: Enter month: 2 Enter day: 1 Enter year: 2017 February 1, 2017 is day 32 of 2017. Sample output2: Enter month: 3 Enter day: 2 Enter year: 2016 March 2, 2016 is day 62 of 2016
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
