Feb 7, 2006 #1 stormbind Technical User Mar 6, 2003 1,165 GB It would seem I do not understand regexp in Java. The following.. System.out.print("hello world".split("/s")); .. outputs gobledigook :/ I wish to split the sentence into an array of valid words. --Glen Memoria mihi benigna erit qui eam perscribam
It would seem I do not understand regexp in Java. The following.. System.out.print("hello world".split("/s")); .. outputs gobledigook :/ I wish to split the sentence into an array of valid words. --Glen Memoria mihi benigna erit qui eam perscribam
Feb 7, 2006 #2 Bong Programmer Dec 22, 1999 2,063 US isn't it "[red]\[/red]s"? _________________ Bob Rashkin Upvote 0 Downvote
Feb 7, 2006 #3 stefanwagner Programmer Oct 19, 2003 2,373 DE And the '\' needs some masking: Code: for (String s : "hello world".split ("\\s")) System.out.println (s); I modified the output to prove: something is happening! seeking a job as java-programmer in Berlin: http://home.arcor.de/hirnstrom/bewerbung Upvote 0 Downvote
And the '\' needs some masking: Code: for (String s : "hello world".split ("\\s")) System.out.println (s); I modified the output to prove: something is happening! seeking a job as java-programmer in Berlin: http://home.arcor.de/hirnstrom/bewerbung