Regular polygon

Submit

Your name:
File:
Open code-statistics:

Language is selected by the extension of the file. See the list of supported languages to know the extension of your language.

Problem

The circle of the radius 1000 of (0, 0) has a center.
Display the coordinates of the regular polygon inscribed in this.
First convex is (1000,0).
Give your answer rounded to the nearest integer.

Options

exec is denied

now post-mortem time, all source codes will be revealed

Sample input:_

3

Sample output:

1000 0
-500 866
-500 -866

Sample input:_

17

Sample output:

1000 0
932 361
739 674
446 895
92 996
-274 962
-603 798
-850 526
-983 184
-983 -184
-850 -526
-603 -798
-274 -962
92 -996
446 -895
739 -674
932 -361

Sample input:_

100

Sample output:

1000 0
998 63
992 125
982 187
969 249
951 309
930 368
905 426
876 482
844 536
809 588
771 637
729 685
685 729
637 771
588 809
536 844
482 876
426 905
368 930
309 951
249 969
187 982
125 992
63 998
0 1000
-63 998
-125 992
-187 982
-249 969
-309 951
-368 930
-426 905
-482 876
-536 844
-588 809
-637 771
-685 729
-729 685
-771 637
-809 588
-844 536
-876 482
-905 426
-930 368
-951 309
-969 249
-982 187
-992 125
-998 63
-1000 0
-998 -63
-992 -125
-982 -187
-969 -249
-951 -309
-930 -368
-905 -426
-876 -482
-844 -536
-809 -588
-771 -637
-729 -685
-685 -729
-637 -771
-588 -809
-536 -844
-482 -876
-426 -905
-368 -930
-309 -951
-249 -969
-187 -982
-125 -992
-63 -998
0 -1000
63 -998
125 -992
187 -982
249 -969
309 -951
368 -930
426 -905
482 -876
536 -844
588 -809
637 -771
685 -729
729 -685
771 -637
809 -588
844 -536
876 -482
905 -426
930 -368
951 -309
969 -249
982 -187
992 -125
998 -63

Ranking

Ruby _

RankUserSizeTimeDateStatistics
1clock860.05942012/06/19 08:13:290B / 50B / 34B
2leonid860.07392012/06/23 04:34:080B / 50B / 33B

Perl _

RankUserSizeTimeDateStatistics
1teebee620.03972012/06/09 18:24:300B / 24B / 35B
2nfouille880.03852012/06/22 19:34:330B / ?B / ?B

Python _

RankUserSizeTimeDateStatistics
1leonid880.08302012/06/15 07:27:150B / 52B / 33B
2clock960.08332012/06/19 08:23:340B / 58B / 33B
3twobit970.08972012/06/13 19:12:030B / 57B / 36B
4hallvabo1050.07282012/06/11 16:11:160B / 67B / 31B
5Defenestrator1080.05692012/06/12 08:25:290B / 73B / 27B

Io _

RankUserSizeTimeDateStatistics
1pooq1110.30912012/06/19 05:56:480B / 78B / 28B

JavaScript _

RankUserSizeTimeDateStatistics
1atami930.06502012/06/22 23:35:160B / 57B / 36B
2nn940.07292012/06/10 20:42:040B / 62B / 32B
3clock960.07252012/06/10 18:01:170B / 64B / 32B
4atami(nn)850.05722012/06/25 20:45:420B / 54B / 31B
5atami910.11472012/06/23 10:26:080B / 55B / 36B

Xtal _

RankUserSizeTimeDateStatistics
1teebee1020.05692012/06/19 05:56:140B / 61B / 40B
2clock1020.08372012/06/19 08:03:390B / 61B / 40B
3pooq1320.08162012/06/17 21:42:070B / 81B / 50B

PARI/GP _

RankUserSizeTimeDateStatistics
1teebee700.07532012/06/22 03:12:120B / 37B / 31B
2clock720.05102012/06/19 01:17:260B / 45B / 26B

Prolog _

RankUserSizeTimeDateStatistics
1pooq1050.16012012/06/17 19:54:270B / 61B / 40B

BASIC _

RankUserSizeTimeDateStatistics
1teebee860.03922012/06/22 21:56:390B / 55B / 26B
2pooq950.06232012/06/22 18:56:450B / 55B / 36B
3teebee850.04082012/06/23 06:10:010B / 55B / 26B

J _

RankUserSizeTimeDateStatistics
1I., S.450.10092012/06/09 06:53:110B / 19B / 26B

K _

RankUserSizeTimeDateStatistics
1teebee560.04702012/06/09 08:35:500B / 23B / 32B
2twobit580.03072012/06/09 08:07:120B / 21B / 35B
3teebee(twobit)460.03062012/08/04 07:04:000B / 22B / 23B
4av(teebee)460.02952012/08/04 07:29:440B / 22B / 23B

C _

RankUserSizeTimeDateStatistics
1inaniwa(rand)990.00072012/06/15 13:14:002B / 52B / 42B
2nu(rand)990.02182012/06/15 14:53:082B / 53B / 41B
3nu1000.04682012/06/14 23:55:070B / 55B / 42B
4leonid1000.01502012/06/15 08:37:472B / 53B / 43B
5ush1000.04782012/06/15 08:46:330B / 55B / 42B
6inaniwa1000.03352012/06/15 10:21:470B / 55B / 42B
7kou1000.04412012/06/15 16:09:010B / 56B / 42B
8nn1020.04612012/06/18 01:24:110B / 58B / 42B
9twobit1030.03262012/06/13 19:09:010B / 57B / 45B
10fill1220.04032012/06/15 12:45:010B / 72B / 49B
11nn(kou)840.03482012/06/25 20:35:300B / 45B / 38B

Haskell _

RankUserSizeTimeDateStatistics
1henkma930.06862012/06/19 06:37:330B / 61B / 30B
2tanakh950.04682012/06/21 20:36:100B / ?B / ?B

Maxima _

RankUserSizeTimeDateStatistics
1pooq881.86962012/06/17 19:49:290B / 49B / 37B

REBOL _

RankUserSizeTimeDateStatistics
1clock920.08402012/06/21 01:55:440B / 57B / 16B
2pooq930.25812012/06/19 19:17:390B / 58B / 17B
3clock900.15532012/06/23 11:43:080B / 55B / 16B

Asymptote _

RankUserSizeTimeDateStatistics
1teebee930.50352012/06/22 17:03:290B / 57B / 34B

AWK _

RankUserSizeTimeDateStatistics
1teebee710.04072012/06/18 09:40:170B / 38B / 32B

Zsh _

RankUserSizeTimeDateStatistics
1nfouille1170.23812012/06/22 19:55:410B / ?B / ?B

R _

RankUserSizeTimeDateStatistics
1pooq901.56492012/06/19 17:53:230B / 56B / 31B
2teebee880.58622012/06/23 10:59:540B / 47B / 39B

Groovy _

RankUserSizeTimeDateStatistics
1nn1003.73302012/06/15 09:54:060B / 63B / 36B
2clock1003.73682012/06/19 01:38:570B / 63B / 33B
3teebee1003.41052012/06/19 06:18:280B / 66B / 33B

Logo _

RankUserSizeTimeDateStatistics
1teebee660.05322012/06/23 02:40:520B / 39B / 17B

Language Ranking_

RankLangUserSizeScore
1JI., S.4510000
2Kav(teebee)469782
3Perlteebee627258
4Logoteebee666818
5PARI/GPteebee706428
6AWKteebee716338
7Cnn(kou)845357
8BASICteebee855294
9JavaScriptatami(nn)855294
10Rubyclock865232
11Pythonleonid885113
12Maximapooq885113
13Rteebee885113
14REBOLclock905000
15Haskellhenkma934838
16Asymptoteteebee934838
17Groovynn1004500
18Xtalteebee1024411
19Prologpooq1054285
20Iopooq1114054
21Zshnfouille1173846

return to the top page