🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.language
Article #652

List class, again...I know...I'm not a pest just learning

#652
From: Scott
Date: Tue, 21 Dec 2004 19:38
19 lines
2035 bytes
What I'm trying to do is remove an item without using a for, or a loop of 
any kind. For example, a number of words from a hungarian dictionary. You 
are told to remove the word Szabadsag.(Some street in Hungary).  It won't 
start with the word repeat( or for or loop or any other similar word which 
is what our method does.

//removes an item from the list
  public void remove(String s) {
    for (int count = 0; count < (data.length - 1); count++) {
      data[count] = data[count + 1];
    }
    data[count + 1] = "";
  }



Is there another variation of this method a I could possibly use?  thanks 
for the help.
 Scott 
Technical Details
Message-ID: <ZY_xd.12526$Ae.2928@newsread1.dllstx09.us.to.verio.net>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news.maxwell.syr.edu!border1.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.dllstx09.us.to.verio.net!verio!newsread1.dllstx09.us.to.verio.net.POSTED!53ab2750!not-for-mail
References: <0Nkwd.12381$Ae.6831@newsread1.dllstx09.us.to.verio.net> <41c82ae7$0$22342$3b214f66@aconews.univie.ac.at> <zDWxd.12514$Ae.10718@newsread1.dllstx09.us.to.verio.net> <41c847c2$0$26996$3b214f66@aconews.univie.ac.at> <IaYxd.12520$Ae.9292@newsread1.dllstx09.us.to.verio.net> <41c857ef$0$26996$3b214f66@aconews.univie.ac.at>

Show Full Headers
Complete Article Headers
X-Google-Thread: f74b3,62cee13431c73458
X-Google-Attributes: gidf74b3,public
X-Google-Language: ENGLISH,ASCII-7-bit
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news.maxwell.syr.edu!border1.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.dllstx09.us.to.verio.net!verio!newsread1.dllstx09.us.to.verio.net.POSTED!53ab2750!not-for-mail
From: "Scott" <swurm@suffolk.lib.ny.us>
Newsgroups: borland.public.jbuilder.java.language
References: <0Nkwd.12381$Ae.6831@newsread1.dllstx09.us.to.verio.net> <41c82ae7$0$22342$3b214f66@aconews.univie.ac.at> <zDWxd.12514$Ae.10718@newsread1.dllstx09.us.to.verio.net> <41c847c2$0$26996$3b214f66@aconews.univie.ac.at> <IaYxd.12520$Ae.9292@newsread1.dllstx09.us.to.verio.net> <41c857ef$0$26996$3b214f66@aconews.univie.ac.at>
Subject: List class, again...I know...I'm not a pest just learning
Lines: 21
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-RFC2646: Format=Flowed; Response
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
Message-ID: <ZY_xd.12526$Ae.2928@newsread1.dllstx09.us.to.verio.net>
Date: Tue, 21 Dec 2004 14:38:29 -0500
NNTP-Posting-Host: 209.139.23.142
X-Complaints-To: abuse@verio.net
X-Trace: newsread1.dllstx09.us.to.verio.net 1103657913 209.139.23.142 (Tue, 21 Dec 2004 19:38:33 GMT)
NNTP-Posting-Date: Tue, 21 Dec 2004 19:38:33 GMT
Organization: NTT/VERIO