Extract out the abscissa and ordinate from an input co-ordinate point.




A co-ordinate is a point on a Cartesian plane, having a value for the x-axis and a value for the y-axis.

It's usually denoted as follows:

(x, y)

The first number inside the parentheses is the value for x-axis, formally known as the abscissa. The second number is the value for the y-axis, formally known as the ordinate.

In this exercise, given a co-ordinate, you ought to extract out the abscissa and ordinate from it, and then print them, each on a new line.

Ask the user to input a co-ordinate with the following prompt message:

Enter a co-ordinate:

The input value should be of the following form: (x,y), where x is the abscissa and y is the ordinate.

You shall assume that there is no space in the input value between x, , and y. So, for example, you don't need to worry about an input like (3, 1) — it'll always be like (3,1).

Once the co-ordinate is given, extract out the abscissa and ordinate from it and output them, each on a new line, after leaving a blank line to start with.

A couple of examples follow:

Enter a co-ordinate: (3,1)

Abscissa: 3
Ordinate: 1
Enter a co-ordinate: (-3.5,10.4)

Abscissa: -3.5
Ordinate: 10.4