APL CodeGolf 의 가을 토너먼트 의 홀 1입니다 . 나는 거기에서 문제의 원래 저자이므로 여기에 다시 게시 할 수있었습니다.
숫자 목록이 주어지면, #
같은 크기의 열 그룹 각각에 몇 개의 숫자가 들어가는가에 대한 가로 막대 그래프 문자를 만드십시오. 예를 들어, 데이터의 범위가 0-100이면 범위는 0–9.9, 10–19.9,…, 90–100입니다. (공식적으로 [0,10), [10,20),…, [90,100]). 두 개 이상의 숫자가 있고 모든 숫자가 같은 것은 아니라고 가정 할 수 있습니다.
예 :
[1,0,0,0,0,0,0,0,0,0]
제공합니다 :
#########
#
[0,1,2,3,4,5,6,7,8,9]
제공합니다 :
#
#
#
#
#
#
#
#
#
#
[0,1,2,3,4,5,6,7,8,9,10]
제공합니다 :
#
#
#
#
#
#
#
#
#
##
[0,1,2,3,4,5,6,7,8,9,10,11]
제공합니다 :
##
#
#
#
#
#
#
#
#
##
[0,-0.5,-1,-1.5,-2,-2.5,-3,-3.5,-4,-4.5,0.5,0,-0.5,-1,-1.5,-2,-2.5,-3,-3.5,-4,1,0.5,0,-0.5,-1,-1.5,-2,-2.5,-3,-3.5,1.5,1,0.5,0,-0.5,-1,-1.5,-2,-2.5,-3,2,1.5,1,0.5,0,-0.5,-1,-1.5,-2,-2.5,2.5,2,1.5,1,0.5,0,-0.5,-1,-1.5,-2,3,2.5,2,1.5,1,0.5,0,-0.5,-1,-1.5,3.5,3,2.5,2,1.5,1,0.5,0,-0.5,-1,4,3.5,3,2.5,2,1.5,1,0.5,0,-0.5,4.5,4,3.5,3,2.5,2,1.5,1,0.5,0]
제공합니다 :
###
#######
###########
###############
#########
###################
###############
###########
#######
###
[9014,9082,9077,9068,8866,8710,9049,8364,8867,9015,9064,9023,9024,8804,8805,8800,8744,8743,8714,9076,8593,8595,9075,9675,8968,8970,8711,8728,8834,8835,8745,8746,8869,8868,9073,9074,9042,9035,9033,9021,8854,9055,9017,9045,9038,9067,9066,8801,8802,9496,9488,9484,9492,9532,9472,9500,9508,9524,9516,9474,8739,9079,8900,8592,8594,9053,9109,9054,9059]
제공합니다 :
#
####
#########
############
######
#########################
###########
#
[0,8,10,13,32,12,6,7,27,9,37,39,95,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,1,2,175,46,48,49,50,51,52,53,54,55,56,57,3,165,36,163,162,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,4,5,253,183,127,193,194,195,199,200,202,203,204,205,206,207,208,210,211,212,213,217,218,219,221,254,227,236,240,242,245,123,125,168,192,196,197,198,201,209,214,216,220,223,224,225,226,228,229,230,231,232,233,234,235,237,238,239,241,91,47,92,60,61,62,45,43,247,215,63,126,42,40,124,59,44,33,243,244,246,248,34,35,30,38,180,64,249,250,251,94,252,96,182,58,191,161,41,93,31,160,167]
제공합니다 :
#############
######################
##########################
#########################
#########################
#
########
################
########################
##########################
[0,1)
포함 0
하고 맨 아래 행은 과를 [9,10]
모두 포함합니다 . 9
10
[0.9,1]
(그리고 아님[0.9,1)
)?