We may have a narrative that blue-eyed people are rude. Whenever someone is rude to you, you may look to see what color eyes they have. If they have blue eyes, this confirms your narrative and you remember it as evidence to support it. If they do not have blue eyes, you dismiss that information as an exception and promptly forget the encounter. This is often how bigotry is formed and maintained.