Path: csiph.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Robert Klemme Newsgroups: comp.lang.java.programmer Subject: Re: How to parse an array? Date: Sat, 24 Jun 2017 12:02:53 +0200 Lines: 29 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable X-Trace: individual.net VWU1/hNDyVE/rWsLAsH4EgNcAT+/xyBPBjtc2+Pp1y0E6Yga8= Cancel-Lock: sha1:soMBLFpw8dx31Ss8jBM7XN6De3w= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 In-Reply-To: Content-Language: en-US Xref: csiph.com comp.lang.java.programmer:36710 On 20.06.2017 21:29, Stefan Ram wrote: > Eric Douglas writes: >> I'm writing a method to take 2 arrays and return the subset of the fir= st array. >=20 > =C2=BBThe subset of the first array=C2=AB makes no sense in English,= > because >=20 > 1.) an array is not a set, so it does not have subsets, and >=20 > 2.) a set might have multiple subsets, it's not clear which > subset you would like to return. Plus, there are neither arrays nor parsing involved. From the code it=20 seems he wants to use a data structure as index into the first one. The = thing is, we do not know where the index numbers come from. Maybe they=20 could be stored in a static array because they never change. Without=20 context the code does not make much sense to me. Cheers robert --=20 remember.guy do |as, often| as.you_can - without end http://blog.rubybestpractices.com/