††††Defensive buildings have been a feature of many civilizations (e.g. the Romans built forts). The castle is one of the most striking examples of this, and many were built in European towns during the Middle Ages.
Many of the earliest castles were single stone towers. Later examples were surrounded by walls. The moat was developed as a further means of defence - it could only be crossed by a drawbridge, which was controlled from the inside of the castle. In later castles the walls surrounding the keep might also be defended by a system of towers. Within these defensive walls were all the resources needed to sustain an army over a long period: food, shelter, weapons, stores and medical facilities. During seige periods the survival of an army would largely be dependent on the extent of the facilities provided. Castles lost their defensive use as cannons evolved, since they were unable to withstand the fire from these weapons.