This code should reverse my input of "123ab 445 Hello" to "ba321 544 olleh", however, I get "olleh 544 ba321" as my output. Why is this happening? : import java.util.StringTokenizer;
import java.util.Scanner;

public class LessNaiveEncryption {

    public static void main(String[] args) {
        Scanner keyboard = new Scanner(System.in);
        System.out.print("Provide an input sentence: ");
        String userInput = keyboard.nextLine();
        StringTokenizer strTokenizer = new StringTokenizer(userInput, " ", true);
        System.out.print("The output sentence is   : ");
        while (strTokenizer.hasMoreTokens()) {
            strTokenizer.nextToken();
        }
        StringBuilder blob = new StringBuilder(userInput);
        blob.reverse();
        System.out.println(blob);
        System.out.print("\n");

    }
}