The C++ as such does not have "graphics" (unless you count std::cout as "drawing command"). One can produce graphics, but that involves quite a lot of low-level code that uses hardware's, OS's, and window system's functions. There are libraries and frameworks that already implement the hard parts.
Actually, the simplest program probably calculates an image buffer (2D array) and saves it in some bitmap image format. Even that "save as" is best done using existing library.
You want an xy-scatter plot. Or do you? Do you want the plot do you want to learn how to produce, for example plots, with C++?
If I remember correctly there are actual graph plotting libraries like kooplot. But if you want more control over it, I'd suggest an SFML vertex array.