Athena and Poseidon competed to become the patron god of Athens. Poseidon struck the earth with his trident and created a saltwater spring. Athena planted an olive tree, which provided food, wood, and oil. King Cecrops preferred Athena's gift, so she became the protector of Athens and gave her name to the city. When Poseidon lost, he flooded Attica with salty water in anger.