First off remember that float has LESS precision then double. Double gives you 16 significant figures while floats give 7 significant figures I believe. So when you are looking for high precision (Money calculations and other things) always use double. If you need even more precision then double can give use longdouble
If I am remembering right I believe doubles give 53 significant bits and floats always have 24 significant bits.
As for sqrt I can't really comment since I don't have much experience with it.
The most important thing is to use type double (or even longdouble) rather than float.
The other thing, if you want to actually display the full result, you will need to change the cout precision. Use something like cout.precision(15); or cout << setprecision(15); in order to show the output to 15 digits of precision for example.
You could try different methods of calculation, but in practice the results will be virtually identical in most cases: distance = pow(pow(x2 - x1, 2.) + pow(y2 - y1, 2.),.5);
Personally I'd prefer something like this, as it requires just a single function call, and it may be more accurate: distance = sqrt((x2 - x1)*(x2 - x1) + (y2 - y1)*(y2 - y1));