2 Replies Latest reply: Sep 30, 2008 5:57 AM by 807589 RSS

    Problem reading a string:Plz help

    807589
      hi gurus

      I am reading some files (in a loop written by some other program). I am reading them line by line and I tokenize each line by space using split function.

      split(" ");

      In resultant string array, somewhere I found NULL or nothing , for example, I print all tokens and it prints like this

      ?penguins/nns? // I print ?on both sides to check any spaces

      ?march/nnp?

      ?? // now here is problem.. both ? combined..nothing between them


      I have checked the file.. this problem occurs where there are multiple spaces between tokens of a line...if I remove others and keep one space it works..
      Now I want to implement a check in program i.e. where there is SPACE or NULL, I should not process it but It does not work

      Please help

      Edited by: kimskams on Sep 30, 2008 4:51 AM