# Combine two cell values into one (Ordered pairs)

Is it possible to take two values in a table and combine to make an ordered pair? See example 2.

You can, but are you using the x and y columns to just check student answers? Because you can use parseOrderedPair to check student input as a coordinate pair. For example, if the intended answer was `(-3,5)` you could use:

``````pair=parseOrderedPair(this.cellContent(1,2))
correct: pair.x=-3 and pair.y=5
``````

The thought was to have them type in the x and y values on this slide and then see how the ordered pair will look, but then on the next slide they will have to type the ordered pair.
So, if i type 2 for x and -4 for y, the last column will then just show them (2,-4). I have it set right now for the table to check their answers for each column.

In that case…

``````cellContent(1,4): `( \${this.cellContent(1,2)} , \${this.cellContent(1,3)} )`
``````
1 Like

Thank you. What about something like this. They place a point into a specific quadrant (open ended) based on the point that is labeled. How would you type the CL to keep this open ended?

Same as accessing a table cell, but using a graph number for any variable in your graph.

``````cellContent(1,4): `(\${graph1.number(`c`)},\${graph1.number(`d`)})`
``````

You could also clean up your graph by making moveable named points instead of having so many sliders (e.g. A=(0,0), B=(0,0), then accessing coordinates of those points:

``````cellContent(1,4): `(\${graph1.number(`A.x`)},\${graph1.number(`A.y`)})`
``````

Great! Thank you for the quick response.