Write a program to determine the value Y given the argument X of a function presented by linked segments, i.e. by a sequence of N points (X(1),Y(1)), (X(2),Y(2)), . . . , (X(N),Y(N)).