001    package ps0.optional;
002    
003    public class StringScrambler {
004    
005        public String reverseWordOrder(String input) {
006            if (input == null) {
007                return null;
008            }
009    
010            // PLACE YOUR IMPLEMENTATION HERE
011    
012            // this line added so skeleton class compiles:
013            return null;
014        }
015    
016    
017        public static void main(String args[]) {
018            StringScrambler scrambler = new StringScrambler();
019            String input;
020            String output;
021    
022            input = "To be or not to be, that is the question.";
023            output = scrambler.reverseWordOrder(input);
024            System.out.println(output);
025    
026            input = "Stressed spelled backwards is Desserts";
027            output = scrambler.reverseWordOrder(input);
028            System.out.println("\n\n" + output);
029        }
030    
031    }