Hi, I have written a function to overload <<.
The while loops are to check if the input is int or double, and reject it if it is not the correct input.
When the code is ran, and an int is input as desired, you have to input twice for the program to accept it.
I am aware this is due to having is >> xin and then while(!(is>>xin)) - does anyone have any suggestions of other ways of doing this?
@Smac89: you make the assumption that all uses of coordinate systems require (or can even allow) real numbers. There are plenty of scenarios where it is more beneficial or even required to use integers instead. And who's to say you can't have coordinates from some other type, like complex numbers?