Question: Please covert java code to swift code Class Q05: import java.util.Scanner; public class 005 { public static void main(String[] args) { int numberOfBabies; System.out.print (Enter

Please covert java code to swift code

Please covert java code to swift code Class Q05: import java.util.Scanner; public

Class Q05: import java.util.Scanner; public class 005 { public static void main(String[] args) { int numberOfBabies; System.out.print ("Enter number of babies: "); Scanner keyboard = new Scanner (System.in); numberOfBabies = keyboard.nextInt(); keyboard.close(); switch (numberOfBabies) { case 1: System.out.println ("Congratulations."); break; case 2: System.out.println("Wow. Twins."); break; case 3: System.out.println ("Wow. Triplets."); break; case 4: case 5: System.out.print ("Unbelieveable; "); System.out.println (numberOfBabies + " babies."); break; default: System.out.println ("I don't believe you."); break

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!