Remove empty "" strings from array String[]

Hi Everyone. What is the BEST method for removing items from an array? I have a String variable, and I need to remove all the “” (empty lines from it).

var linesToCheck : String[];
var lines : String[];

linesToCheck = script.text.Split( '

'[0] );

  // Remove any empty lines from script
  for ( var line in linesToCheck )
  {
        if ( line != "" )
           lines.Add( line );
   }

I just figured out the solution to my problem myself, which was to simply change my array type from “String” to “new Array();”