Mad Libs is a children\'s game in which they provide a few words that are then incorporated into a silly story. The game helps children understand different parts of speech because they are asked to provide specific types of words. For example, you might ask a child for a noun, another noun, an adjective, and a past-tense verb. The child might reply with such answers as table, book, silly, and studied. The newly created Mad Lib might be: Mary had a little table Its book was silly as snow And everywhere that Mary studied The table was sure to go. Create a Mad Libs program that asks the user to provide at least four or five words, and then create and display a short story or nursery rhyme that uses them. Save the file as MadLib.java. Solution MadLib.java import java.io.*; class MadLib { private static void intro() { String msg = \"This is a Mad-Lib game. I will prompt \" + \"you for five words.\ \"; System.out.print(msg); } private static String getInput(String msg) throws IOException { BufferedReader stdin; stdin = new BufferedReader(new InputStreamReader(System.in)); System.out.print(msg); return stdin.readLine(); } private static void printOutput (String noun1, String adverb, String noun2, String pronoun, String adj) { String output = \"\ Three blind \" + noun1 + \", \ Three blind \" + noun1 + \", \ see \" + adverb + \" they run!\" + \"\ see \" + adverb + \" they run!\ They all ran after the farmer\'s \" + noun2 + \"\ Who cut off their tails,\ With a carving knife.\ Did you ever see \" + pronoun + \" a thing in your life,\ As three \" + adj + \" mice.\"; System.out.println(output); } public static void main(String[] args) throws IOException { intro(); String noun1 = getInput(\"Enter a noun : \"); String adverb = getInput(\"Enter a adverb : \"); String noun2 = getInput(\"Enter a another noun : \"); String pronoun = getInput(\"Enter a pronoun : \"); String adj = getInput(\"Enter an adjective : \"); printOutput(noun1, adverb, noun2, pronoun, adj); } } Output: This is a Mad-Lib game. I will prompt you for five words. Enter a noun : mice Enter a adverb : how Enter a another noun : wife Enter a pronoun : such Enter an adjective : blind Three blind mice, Three blind mice, see how they run! see how they run! They all ran after the farmer\'s wife Who cut off their tails, With a carving knife. Did you ever see such a thing in your life, As three blind mice..