If you will use sort from <algortihm>, you will get AC.
http://www.cplusplus.com/reference/clibrary/cstdlib/qsort/I changed 
int compare( const void *arg1, const void *arg2 )
{
if(((Point2*)arg1)->angle>((Point2*)arg2)->angle)
return -1;
else
return 1; 
to 
int compare( const void *arg1, const void *arg2 )
{
if(((Point2*)arg1)->angle>((Point2*)arg2)->angle)
return 1;
else
return -1; 
according to conditions presented in the href above. On my computer I get answer "1 4" on first test, but on server in gets WA #1. 
/* qsort example */
#include <stdio.h>
#include <stdlib.h> 
int values[] = { 40, 10, 100, 90, 20, 25 }; 
int compare (const void * a, const void * b)
{
  return ( *(int*)a - *(int*)b );
} 
int main ()
{
  int n;
  qsort (values, 6, sizeof(int), compare);
  for (n=0; n<6; n++)
     printf ("%d ",values[n]);
  return 0;
}