How can I add flooring to an attic floor with electrical wires running across it?
Definitely consider the first couple of comments regarding whether the joists are even strong enough to support a floor.

Presuming the joists are strong enough, you could probably run firring strips on top of the existing joists, these could be 2x4's on their sides, or you could rip them down to 2x2's. You would either notch them or just cut them and leave a gap every place a wire crosses the original joist. You would have to put metal plates across the gaps to protect the wires. There just isn't enough depth otherwise and you'll drive screws or nails through the wire when you install the flooring.



Alternatively, you may consider running new "joists" (check around with some builders, but even 2x4's might be sufficient if you're on 16" centers?) ACROSS the existing joists, perpendicular to them, rather than directly on top of them in the same direction. You can probably reduce the number of notches you need to cut for the wiring this way, and it would also raise the new floor high enough over the wires that you don't need to put a steel plate over each wire.

It would be pretty easy to secure these "cross joists," especially if you run them clear over the tops of the end walls.

If your original joists aren't strong enough to support a floor, you could either sister the joists, or possibly place new joists on top of them that are strong enough and are supported on the load-bearing end walls. But if you go there, you want to get a builder or engineer/architect involved if you don't have the background to design it yourself.

There might be something in the N.E.C. about a minimum distance for the wiring under the flooring, as well, despite the use of the metal plates at the points where they cross.

What's to keep somebody (even a kid) from driving a nail or screw into the floor at some future date and drive it through the wire?

You might consider laying sheet metal strips down the entire length of all of these cables.

The N.E.C. does say that cables stapled across the tops of joists the way you describe have to be protected with boards running alongside the cables (so someone stepping on the cable doesn't damage it--the board helps keep the weight off the cable).