I've built 4 gas engined bikes and 3 electric powered bikes. All were built using an inexpensive big box store bike as a base. All cost $200.00 or less, but all needed upgrades in wheels, tires, and brakes. One needed a bearing upgrade right out of the box. That particular bike was such a piece of garbage that I eventually gave up trying to make it work well and scrapped the frame, moving all the good components to a different, new bike. The cost of a new bike is an indication of quality, at least to some extent. You should pick the base bike with care so you avoid the mistake I made. Stay away from any new bike under about $150.00.
As Fabian said, disc brakes are by far the best, but I don't consider them an absolute necessity. If you live in an area with lots of hills, then go with, at the minimum, a disc brake on the front wheel. I would also upgrade the front disc brake to a BB5 caliper, or better. I think quality linear pull rim brakes are acceptable in mostly flat country. A friend of mine blew 2 tires on a long, fairly steep downhill, with a bad, loss of control crash due to the blowouts. The blowouts were caused when the tires/inner tubes melted on the rim due to the high heat generated by trying to control speed on the downhill. It can happen, but not with discs. When I am using rim brakes, I upgrade the brake pads with better quality pads from Rav-X or Quietstop or the like. If you go with an older used bike, be aware, the 1970s bikes with side pull or center pull brakes have such short brake arms there is little mechanical advantage and the brakes won't stop you in a short distance! Replace them with new brakes!! Some of those bikes also had steel wheels, chrome plated or not. Replace all steel wheels with alloy wheels if you use rim brakes. Steel rim brakes don't work worth a darn when wet! Also carefully check any used, steel frame bike for rust. Once rust has started it is fairly difficult to stop completely.
With any inexpensive or used bike you should take the bike completely apart, right down to the frame. You will be amazed that some bolts and screws are WAAAAAY overtightened, and some are very loose. That lack of care when cheap bikes are assembled is nearly criminal, one reason they are so cheap, and can kill you at speed. Regrease all the bearings with high quality grease, like good auto wheel bearing grease, and locktite all the fasteners as you put it back together.