Buying a new bicycle has two big advantages over buying a second hand bike. The first is that a new bike will still have its original manufacturer's warranty (as will all of its parts). It is true that some second hand bikes also come with warranties, as do many replacement parts, but the warranties on new bicycles are usually of greater length, and thus of more value.
The second advantage is that new bicycles are more likely to incorporate the newest technological advances in bicycle and bicycle accessory design.
There are numerous examples of this to be had:
Carbon fibre frames, wheels, et al, were first introduced in the late nineties, and have undergone a continual process of refinement since then
Thermoplastic frames and such are even newer, and although the technology lacks maturity, early indications are promising
In the last decade, toe-clips on pedals (to ensure that the rider's foot remains in contact with the pedal) have been largely made obsolete by the introduction of click-on pedals.
Newer saddle designs take better account of the damage to the genitals that older models sometimes caused, and include the so-called noseless saddles and other designs intended for use specifically by women or men.
A wide variety of suspension systems have come into use over the last two, cushioning the rider against various impacts.
New materials and spoke designs have made wheels that are stronger, lighter or more aerodynamic than their predecessors
The coaster and calliper brakes that characterised bikes in the seventies and eighties have now largely fallen from use, in favour of disc and drum brake designs that are more efficient and safer to use.
Bicycle gearing has vastly increased in its range of options and the precision of options available.
Trip computers are now a common accessory, and sometimes even a default feature of newer bikes.
Newer lights are both more powerful and weigh less than older lights, in addition, newer lights are almost always battery powered, to avoid the drag and inefficiency of dynamo lights.
Fittings on the bike to allow you to carry a pump or water bottle are now standard, and many bikes come with a water bottle.
Newer bikes also allow for a much better match of the bike you're buying to your actual needs. Within the broader categories of Road, Racing, Mountain and BMX are various subcategories, each for some specialisation of the larger category. In addition to these, there are also numerous hybrid forms, which combine aspects of two or more bicycle subcategories.
Buying a new bicycle new also means that you can speak directly to the seller, and get their assistance in finding the bike that's right for your needs. It's much better to find out that you had the wrong idea about what sort of bike you wanted before you make a purchase than after, and much, much easier (not to mention cheaper) to correct that error sooner than later.