A computer uses memory to store and process data. Primary memory, also called RAM, is faster but volatile, while secondary memory such as hard disks can permanently store large amounts of data but is slower to access. Different types of computer networks include local area networks (LANs) that connect devices within a building, metropolitan area networks (MANs) that span a city, and wide area networks (WANs) that connect multiple cities and countries over long distances.