I just saw a great and simple project that does just this:
http://www.youtube.com/watch?list=PLFA57ACAC0F0DE0D1&feature=player_detailpage&v=cwiLQWJq2LQ
![enter image description here](https://i.stack.imgur.com/R7qjn.jpg)
The project is by Alan Yates:
http://www.vk2zay.net/
As I understand it, it uses a high impedance gate of a JFET to detect fluctuations in the E-field in the wires due to noise on the mains. The signal is amplified using a BJT to make sound on a piezoelectric speaker. If a light is burned out it the E-field will exist on the wire going into the light, but, not on its exit wire. Using this principal it is easy to locate the burned light. He applies this to incandescent light string, but, the same principal would apply to an LED string.
Do you know the \$V_f\$ (forward voltage drop) of your LEDs? This is the value you need to know in order to calculate everything else.
Fortunately you can determine it by measuring. Connect an LED in series with a 330 ohm resistor (or 470 or 1k, whatever is handy in this range) and your multimeter in current measurement mode. Apply 9V and note the current.
Let's say you used a 330 ohm resistor and measured 20mA. This would mean the resistor has 0.20mA * 330Ω = 6.6V across it. That leaves 2.4 for the LED.
(This is a convenient made-up number, because many LEDs have a forward current of 20mA. If you measure more or less, you should change values until you get closer to 20mA or whatever the typical forward current of your LED is. If you don't know, you are probably safe assuming 20mA.)
Knowing this, you can divide 9 by the now-known \$V_f\$ of the LED: \$\frac{9}{2.4} = 3.75\$. Since you can't have partial LEDs, you can connect three LEDs in series, meaning you would have six runs of three and one run of two for a total of 20 LEDs. A current-limiting resistor would be needed on each series run.
To calculate those, again just use Ohm's law. Three LEDs with a \$V_f\$ of 2.4 gives a total voltage drop of 7.2. Subtract that from 9 to get the voltage drop on the current-limiting resistor. To have 20mA in the series, we can calcuate the resistor value (V/I) as \$\frac{1.6V}{0.02A}=80\Omega\$.
For the series run with just two LEDs: Two LEDs at 2.4V is 4.8V, subtracted from 9 is 4.2. The resistor then is \$\frac{4.2V}{0.02A}=210\Omega\$.
Now, all of these numbers are made-up, but it should give you the means to calculate them for your actual components.
Here is a schematic for this series-parallel circuit:
![schematic](https://i.stack.imgur.com/N7mcc.png)
simulate this circuit – Schematic created using CircuitLab
Note that 80 and 210 ohm values are "ideal" and using the commonly available 100 and 220 ohm values (respectively) would be just fine.
Edit:
Each run of series-connected LEDs will draw 20mA (again, assuming that's the typical \$I_f\$ of the LEDs you are using). With seven such branches, the total current should be about 140mA.
A typical 9V battery has approximately a 500 mAh capacity with a 100 mA discharge, so I would expect no more than 3.5 hours run time (\$\frac{500}{140}\$) with a fresh alkaline battery.
Best Answer
Each LED has it's own internal resistance.
When you consider the typical tolerance on AC lines is < 10%, and the tolerance on LED internal resistance can be up to 50% about the rated forward voltage, how many LEDs do you need to survive a 10% voltage tolerance without resistors and not exceed its current rating?
Well that depends on what nominal current you choose and the statistical variation of internal resistance on all batches. I know the variation can be extremely small (<1%) in a single batch. So the prudent choice is to use that value for the maximum voltage tolerance.
Consider an LED with the transfer function of Vf=2.8 + If*Ri for If rated @ 20mA and Ri = 16 +/-50% worst case i.e. Vf 2.96 to 3.28 or 3 to 3.3V. or 3 (+0.3V/-0) (Some are better and worse than this example)
Now consider;
120V/3.3V = 36 LEDs
The LED tolerance on 40 LEDs is 40 *0.3V = 12.3V
Conclusion
the more parts in series, the greater tolerance to applied voltage.