Little late on this, but there's an easier way to do the first one:
Grab a balance scale, take one coin from eash machine (total of 10). Divide up into groups of 3, with one x-tra. Put two groups on either side of the scale, if they even, replace one of the groups with the third, if still even it's the random. If one of the previous were not even, take the lighter group and put one coin (from that group) on either side of the scale. If those two are even, it's the random, if not, it's the lighter one.
Make sense?
L8
__________________
|