7.20 ReverseStrings Complete the code for the ReverseStrings such that the user can use a stack to store Strings and then output the Strings in the opposite order from which they were entered. You can ignore the warning: [unchecked] unchecked cast. Here is the output from a sample run: the beginning of a story is often different than the end of a story Reverse is: the end of a story is often different than the beginning of a story ReverseStrings.java import java.util.Scanner; public class ReverseStrings{ public static void main(String[] args){ Scanner keyboard = new Scanner(System.in); StackInterface<String> stack = new ArrayBasedStack<String>(3); String line; for(int i = 1; i <= 3; i++){ //enter you code here to prompt the user for a line of text, save the text, then add to the stack } System.out.println("Reverse is:\n"); for(int i = 1; i <=3; i++){ //enter the code to print the lines in reverse } }//end main }//end class ArrayBasedStack.java public class ArrayBasedStack<T> extends Object implements StackInterface<T>{ private int top; private T [] stack; public ArrayBasedStack(){ super(); top = -1; stack = (T[])new Object[10]; } public ArrayBasedStack(int size){ super(); top = -1; if(size > 0){ stack = (T[]) new Object[size]; } else{ stack = (T[]) new Object[10]; } } public void push(T item) { if(top < stack.length - 1) { top++; stack[top] = item; } } public void pop() { if(top >= 0) { stack[top] = null; top--; } } public String peek() { String topItem; if(top >= 0) { topItem = stack[top].toString(); } else { topItem = "The stack is empty"; } return topItem; } } .