Reversed Sentence - Stack Implementation
===

This code is inside the `main` function:

	Scanner input = new Scanner(System.in);
	
	System.out.println("Type a sentence");
	String sentence = input.next();
	
	Stack<Character> stk = new Stack<Character>();
	int i = 0;
	
	while (i < sentence.length())
	{
		while (sentence.charAt(i) != ' ' && i < sentence.length() - 1)
		{
			stk.push(sentence.charAt(i));
			i++;
		}
		stk.empty();
		i++;
	}

And this is the `empty()` function:

	public void empty()
	{
		while (this.first != null)
			System.out.print(this.pop());
	}

It doesn't work properly, as by typing `example sentence` I am getting this output: `lpmaxe`. The first letter is missing and the loop stops instead of counting past the space to the next part of the sentence.