{"trustable":true,"sections":[{"title":"","value":{"format":"HTML","content":"\u003cp\u003eThere is a map of a minefield. The border of the minefield is a polygon which has not got self-intersections or self-contacts. There are two points \u003cb\u003eA\u003c/b\u003e and \u003cb\u003eB\u003c/b\u003e outside of this minefield or on its border. You need to find the minimum length way from \u003cb\u003eA\u003c/b\u003e to \u003cb\u003eB\u003c/b\u003e. Obviously the way can not cross the minefield. However, it may contact edges or vertices of the bounding polygon.\u003c/p\u003e"}},{"title":"Input","value":{"format":"HTML","content":"\u003cspan lang\u003d\"en-us\"\u003e\u003cp\u003eThe input consists of several lines. The first line contains four numbers \u003cb\u003eX\u003csub\u003eA\u003c/sub\u003e\u003c/b\u003e, \u003cb\u003eY\u003csub\u003eA\u003c/sub\u003e\u003c/b\u003e, \u003cb\u003eX\u003csub\u003eB\u003c/sub\u003e\u003c/b\u003e and \u003cb\u003eY\u003csub\u003eB\u003c/sub\u003e\u003c/b\u003e – the coordinates of two given points. The second line contains integer number \u003cb\u003eN\u003c/b\u003e, 3 ≤ \u003cb\u003eN\u003c/b\u003e ≤ 100 – the number of vertices of the bounding polygon. Finally, each of the next N lines contains a coordinates \u003cb\u003eX\u003c/b\u003e and \u003cb\u003eY\u003c/b\u003e of one polygon vertex, in the counterclockwise order. All the coordinates are integer numbers between −100000 and 100000. The numbers are separated by one or more spaces.\u003c/p\u003e\u003c/span\u003e"}},{"title":"Output","value":{"format":"HTML","content":"\u003cp\u003eThe output consists of one line containing the length of a shortest safe way, with the accuracy 0.0001.\u003c/p\u003e"}},{"title":"Sample","value":{"format":"HTML","content":"\u003ctable class\u003d\u0027vjudge_sample\u0027\u003e\n\u003cthead\u003e\n \u003ctr\u003e\n \u003cth\u003eInput\u003c/th\u003e\n \u003cth\u003eOutput\u003c/th\u003e\n \u003c/tr\u003e\n\u003c/thead\u003e\n\u003ctbody\u003e\n \u003ctr\u003e\n \u003ctd\u003e\u003cpre\u003e0 0 5 5\r\n4\r\n1 0\r\n3 0\r\n3 2\r\n1 2\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003e7.2361\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n"}}]}