As a teenager, I started with one of these:
However, when I started riding again, I was desperate for information regarding fitness and related goals. I started with a wireless Cateye, but in short order I ended up on the Garmin 800 path and use it to map a new and interesting routes over longer distances. Logging distance and average speed with Garmin Connect made record keeping easy, but Strava is my favorite tool. I can keep mileage by bike, keep track of upgrades and tires, track my fitness and yes, it does provide a virtual competition on segments that is great if you are into fitness and if used wisely (compete on climbs not descents). As others have said, the mounts on every bike makes it really easy and the device keeps odometer mileage for up to 5 bikes on the device (I have one generic bike that I then alter to the correct bike when uploading to Strava).
This being C&V though, I just recently picked up a 1974 Schwinn Sprint that must have one of the earlier cycling computers. I have not tried to replace the batteries yet (I am betting this device doesn't take a CR2032). Wired sensor disc is intact on the wheel.