Menu

(Solved) : 311 Lab Mad Lib Loops Mad Libs Activities Person Provide Various Words Used Complete Short Q44102096 . . .

3.11 LAB: Mad Lib – loops

Mad Libs are activities that have a person provide variouswords, which are then used to complete a short story in unexpected(and hopefully funny) ways.

Write a program that takes a string and integer as input, andoutputs a sentence using those items as below. The program repeatsuntil the input string is quit 0.

Ex: If the input is:

apples 5shoes 2quit 0

the output is:

Eating 5 apples a day keeps the doctor away.Eating 2 shoes a day keeps the doctor away.

Note: This is a lab from a previous chapter that now requiresthe use of a loop.

import java.util.Scanner;

public class LabProgram {
public static void main(String[] args) {
/* Type your code here. */
}
}

Expert Answer


Answer to 3.11 LAB: Mad Lib – loops Mad Libs are activities that have a person provide various words, which are then used to compl…

OR