arrays splitting strings java -


I'm sure this is a fairly easy question for anyone, but I think it's the best way to do it as a relative. Tell me the beginners.

I am dividing a large file (string temporary) into approximately 100 strings and setting it as an array, but I do not know the exact number of strings.

  string [] idf = temp.split ("==========="); String class 1 = IDF [0]; String class 2 = IDF [1]; String Class 3 = IDF [1]; e.t.c.  

What's the best way to ensure that I can split all the stars and store them in an array?

Any suggestions or hints will be most thanked

You can do this Are:

  string list = "hey, how are you"; String [] strarray = list.split ("\\ s +"); (String str: stray) {System.out.print (str); }  

Comments

Popular posts from this blog

Pass DB Connection parameters to a Kettle a.k.a PDI table Input step dynamically from Excel -

multithreading - PhantomJS-Node in a for Loop -

c++ - MATLAB .m file to .mex file using Matlab Compiler -