Java

 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me



Go Back   Tutorialized ForumsWeb Design & DevelopmentJava

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Tutorialized Forums Sponsor:
  #1  
Old December 6th, 2010, 12:41 PM
logan1988 logan1988 is offline
Registered User
Tutorialized Newbie (0 - 499 posts)
 
Join Date: Dec 2010
Posts: 1 logan1988 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 24 m 57 sec
Reputation Power: 0
Java: Removing a numerical item from an ArrayList<String>

Ok, I am at my wits end trying to figure out how to solve this.

What I have is a program which reads a .txt file, parses it, and the places each word in an ArrayList of type String. The problem is that some of these words are not words, they are numerical in value.

So for instance, they ArrayList may look like this:

[hello, 1, world, 4/5, this, 3/1, is, 7, a, test, 20]

What I want to do is go through each element in the list, check if it is numerical in value and remove it from the list completely.

Therefore the above example should look like this:

[hello, world, this, is, a, test]

I wish I had some code to show you, but what I have is a complete mess as I keep deleting things and generally stressing myself out over this problem when it seems so simple.

Any help would be greatly appreciated!

Thanks in advance.

Last edited by logan1988 : December 6th, 2010 at 12:51 PM.

Reply With Quote
Reply

Viewing: Tutorialized ForumsWeb Design & DevelopmentJava > Removing a numerical item from an ArrayList<String>


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 

Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.

© 2003-2017 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap