In java how can I delete an item in the text?? using file handling techniques?
-
I have a text file with Songs, followed by Artists, followed by Categories,, all stored as String arrays. How can I delete a particular element in the array. For example this is my text. Back in Black ACDC Rock Boom P.O.D. Metal American Idiot Green Day Punk I want to delete a song from the collection. American Idiot just for example. How can I do it??
-
Answer:
You cannot delete elements from an array in Java. If you need a more flexible container for data, consider using an array list: http://docs.oracle.com/javase/tutorial/collections/index.html http://docs.oracle.com/javase/7/docs/api/java/util/ArrayList.html
Pillar of Autumn at Yahoo! Answers Visit the source
Other answers
You cannot delete elements from an array in Java. If you need a more flexible container for data, consider using an array list: http://docs.oracle.com/javase/tutorial/collections/index.html http://docs.oracle.com/javase/7/docs/api/java/util/ArrayList.html
Justin
Related Q & A:
- How can i delete the links that posted on my status?it bothers my im to frends.pls help me delete that?Best solution by Yahoo! Answers
- How may I delete old attachments from my attachment /photo file?Best solution by Yahoo! Answers
- How can I delete alternate emails I created?Best solution by answers.yahoo.com
- For eBay, how do I delete an item that I am selling?Best solution by Yahoo! Answers
- How can I get the font size of text in elements within a webpage?Best solution by Stack Overflow
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.