So I made this 3D Distance calculator where you enter in the coordinates of one point and then the coordinates of the other point and it gives you the distance between the two points. It then prompts you to enter in a 1 to restart so it runs the actual program 2 times. The math seems to be correct and the program works. The question is looking it over, what do you think of it and the way it is structured? Does it look messy? Is their a different way I could structure it to make it look more concise and to the point?
It looks fine, but you are making a second variable called distance, when you could just use the first one. Also you are calling formula twice. did you want the code to run twice? It seems to me anyway that it would make more sense like this: