Path: csiph.com!eternal-september.org!feeder.eternal-september.org!reader02.eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail From: Cecil Westerhof Newsgroups: comp.lang.java.programmer Subject: Inclusive or exclusive array Date: Tue, 30 Jul 2019 18:24:19 +0200 Organization: Decebal Computing Lines: 14 Message-ID: <87zhkvmqx8.fsf@munus.decebal.nl> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: reader02.eternal-september.org; posting-host="836bcd58d7669a6d0685c847623fc8c3"; logging-data="2403"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/Z3RgqYUylRAa07a+UBGE6BHSqGsaX+7c=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) Cancel-Lock: sha1:BMuLYOEr/Zy1P6VUaYDFt6VBjBg= sha1:TZy5MwgBY8MgcCizLYvIMA2cBVk= Xref: csiph.com comp.lang.java.programmer:39029 I am writing the following method: Long[] getFibonacciArray(int from, int to); What is more logical: an inclusive or an exclusive array? Should: getFibonacciArray(12, 12) return 'Long[1] { 144 }', or 'Long[0] { }'? -- Cecil Westerhof Senior Software Engineer LinkedIn: http://www.linkedin.com/in/cecilwesterhof