When the man at the back of the line was asked "Do you know your hat color?", he replied "No". When the man that was second in line was then asked "Do you know your hat color?" he replied "No". When the man at the front of the line was asked "Do you know your hat color?" he replied "Of course".
What color of hat was the man at the front of the line wearing?