NNTP-Posting-Date: Wed, 27 Feb 2013 05:58:20 -0600 Date: Wed, 27 Feb 2013 11:58:18 +0000 From: lipska the kat <"nospam at neversurrender dot co dot uk"> Organization: Trollbusters 3 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120410 Thunderbird/11.0.1 MIME-Version: 1.0 Newsgroups: comp.lang.java.programmer Subject: Re: BlueJ don't know what i did wrong References: <638ed624-9eba-44eb-bcbf-68466e5bb5f1@googlegroups.com> <42d76fca-d365-4030-ae8c-07a806eab87c@googlegroups.com> <1wtai7dd80h80$.6rbtwoyou3gh.dlg@40tude.net> <5q6dnc3pF_HJzLfMnZ2dnUVZ7s-dnZ2d@bt.com> <77afaabf-ec0f-46d6-b3ea-d8f186dbf7e4@googlegroups.com> <512c2745$0$289$14726298@news.sunsite.dk> <3a2dnXBuTbOY4rHMnZ2dnUVZ8iWdnZ2d@bt.com> <0I%Ws.96474$Ln.24770@newsfe22.iad> <672dncokKZ13AbHMnZ2dnUVZ8oadnZ2d@bt.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Message-ID: Lines: 63 X-Usenet-Provider: http://www.giganews.com X-AuthenticatedUsername: NoAuthUser X-Trace: sv3-ZTTh330PQjGMdCyxcl2QUP4FcnWIa9otlPiRapA85zHXE535Yi11abON9geOdqf17Lofjlw/hHPaFmM!IMZcCi/IWD3YmvUKjGdlHDaDjN+a8I0CuMseQXrBGeFYQa8B73NwQGv9hDThzV8AX3g5Z5rlb5U= X-Complaints-To: abuse@btinternet.com X-DMCA-Complaints-To: abuse@btinternet.com X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.40 X-Original-Bytes: 4058 Path: csiph.com!usenet.pasdenom.info!news.stben.net!border3.nntp.ams.giganews.com!Xl.tags.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!local2.nntp.ams.giganews.com!nntp.bt.com!news.bt.com.POSTED!not-for-mail Xref: csiph.com comp.lang.java.programmer:22572 On 27/02/13 10:45, Arved Sandstrom wrote: > On 02/26/2013 07:30 AM, lipska the kat wrote: >> On 26/02/13 09:59, Arved Sandstrom wrote: >>> On 02/26/2013 05:23 AM, lipska the kat wrote: [snip] >>>> >>> A deque (double ended queue) is a queue generalization. Despite the >>> name, a deque is not a queue, but a queue is a deque. >> >> You have this the wrong way round I'm afraid. >> A Deque 'is a' Queue because it extends Queue, you can call Queue >> methods on Deque but you cannot call Deque methods on Queue. >> A Queue is most definitely NOT a Deque. >> >> These are first year comp sci concepts really. > [ SNIP ] > > You want to read up on generalization and specialization. ======================= Generalization ============================== http://en.wikipedia.org/wiki/Generalisation ... concept A(Queue) is considered a "generalization" of concept B(Deque) if and only if: every instance of concept B (Deque) is also an instance of concept A (Queue); -- this is obviously the case as Deque extends Queue and there are instances of concept A(Queue) which are not instances of concept B(Deque) -- again true, you can't call Deque methods on Queue types ====================================================================== You appear to be arguing against this with your assertion that "A deque (double ended queue) is a queue generalization" In fact a Deque is a Queue *specialization* ============================ Specialization ========================== http://en.wikipedia.org/wiki/Specialization_%28logic%29 ... Concept B(Deque) is a "specialisation" of concept A(Queue) if and only if: every instance of concept B (Deque) is also an instance of concept A (Queue); and there are instances of concept A(Queue) which are not instances of concept B(Deque). ---see above ===================================================================== Still not convinced ? lipska -- Lipska the Kat©: Troll hunter, sandbox destroyer and farscape dreamer of Aeryn Sun