Golfy ARrays

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

A golfy array is an array of positive integers, where each element is higher than or equal to the arithmetic mean of all the previous terms. Print 1 if the array is golfy and 0 otherwise.

Options

no deadline, the server will not save your submission

Sample input:_

[1, 4, 3, 8, 6]

Sample output:

1

Sample input:_

[6, 6, 6, 6, 6]

Sample output:

1

Sample input:_

[45, 45, 46, 43]

Sample output:

0

Ranking

Ruby _

RankUserSizeTimeDateStatistics
1mitchs60.02232017/10/15 03:25:380B / 4B / 1B
2Histocrat60.02372017/10/17 04:54:520B / 2B / 4B

Ruby2 _

RankUserSizeTimeDateStatistics
1Histocrat60.14382017/10/18 04:36:350B / 2B / 4B
2mitchs60.14622017/10/18 07:41:410B / 2B / 4B
3letranger120.14612017/10/23 18:31:150B / 9B / 3B

Perl _

RankUserSizeTimeDateStatistics
1brx90.00042018/01/08 21:54:160B / 6B / 3B
2llhuii90.00042018/01/08 22:12:110B / 6B / 3B

Python _

RankUserSizeTimeDateStatistics
1rolf130.07092017/10/15 00:03:400B / 9B / 3B
2mitchs130.06972017/10/15 06:38:450B / 9B / 3B
3llhuii130.06962018/01/08 22:18:050B / 9B / 3B
4test200.07432017/11/03 04:48:050B / 13B / 5B
5Someone210.11092017/10/15 20:09:260B / 12B / 9B

Python3 _

RankUserSizeTimeDateStatistics
1mitchs150.11552017/10/15 06:40:300B / 8B / 7B
2llhuii150.11872018/01/08 22:24:050B / 8B / 7B
3fill210.11842017/11/10 15:42:220B / 14B / 7B
4mypetlion210.11442017/12/02 00:39:160B / 14B / 7B
5rolf250.11802017/10/14 23:55:140B / 12B / 13B

JavaScript _

RankUserSizeTimeDateStatistics
1ETHproductions170.03912017/10/18 03:37:310B / 13B / 3B
2FizzyTea170.06652017/11/08 02:11:020B / 13B / 3B

Xtal _

RankUserSizeTimeDateStatistics
1pooq290.04042017/11/26 22:12:190B / ?B / ?B

PARI/GP _

RankUserSizeTimeDateStatistics
1mitchs150.07132017/10/15 06:20:490B / 11B / 4B

BASIC _

RankUserSizeTimeDateStatistics
1pooq163.00452017/11/25 21:29:290B / ?B / ?B

J _

RankUserSizeTimeDateStatistics
1pooq120.05502017/11/26 17:21:570B / ?B / ?B

C _

RankUserSizeTimeDateStatistics
1llhuii270.00042018/01/08 22:22:240B / 15B / 12B

Haskell _

RankUserSizeTimeDateStatistics
1henkma310.03622017/10/24 21:32:470B / ?B / ?B
2yuki480.03372017/11/27 09:11:430B / 30B / 16B

AWK _

RankUserSizeTimeDateStatistics
1mitchs80.03112017/10/15 16:50:500B / 3B / 4B
2teebee80.03232017/10/16 06:52:440B / 2B / 6B
3Hendrik80.03112017/10/29 06:14:530B / 3B / 5B
4llhuii80.03242018/01/08 22:20:330B / 5B / 3B

jq _

RankUserSizeTimeDateStatistics
1pooq80.04122017/11/30 02:53:010B / ?B / ?B

Bash (builtins) _

RankUserSizeTimeDateStatistics
1llhuii140.00042018/01/09 15:08:410B / 6B / 7B

xgawk _

RankUserSizeTimeDateStatistics
1mitchs80.03182017/11/05 12:04:120B / 3B / 4B
2llhuii80.03862018/01/08 22:20:380B / 5B / 3B

R _

RankUserSizeTimeDateStatistics
1pooq180.29712017/11/25 22:10:000B / ?B / ?B

Brainfuck _

RankUserSizeTimeDateStatistics
1mitchs (cheat)140.06292017/10/15 15:32:590B / 0B / 14B
2mitchs230.03132017/10/15 15:39:320B / 0B / 23B

GolfScript _

RankUserSizeTimeDateStatistics
1mitchs30.05102017/10/15 04:00:500B / 1B / 2B

gs2 _

RankUserSizeTimeDateStatistics
1mitchs20.18992017/10/15 04:02:340B / 1B / 1B
2whio20.17692017/10/17 00:29:100B / 2B / 0B

Burlesque _

RankUserSizeTimeDateStatistics
1Hendrik50.03302017/10/15 01:04:470B / 3B / 2B

Scala _

RankUserSizeTimeDateStatistics
1rotary-o225.31082017/10/15 14:15:300B / 18B / 4B
2Hendrik224.17402017/11/25 12:38:070B / 15B / 7B

Language Ranking_

RankLangUserSizeScore
1gs2mitchs210000
2GolfScriptmitchs36666
3BurlesqueHendrik54000
4Rubymitchs63333
5Ruby2Histocrat63333
6AWKmitchs82500
7xgawkmitchs82500
8jqpooq82500
9Perlbrx92222
10Jpooq121666
11Pythonrolf131538
12Brainfuckmitchs (cheat)141428
13Bash (builtins)llhuii141428
14PARI/GPmitchs151333
15Python3mitchs151333
16BASICpooq161250
17JavaScriptETHproductions171176
18Rpooq181111
19Scalarotary-o22909
20Cllhuii27740
21Xtalpooq29689
22Haskellhenkma31645

return to the top page