question: public static void outString ( DataOutputStream dos , String s ) throws IOException { dos . writeShort ( ( short ) s . length ( ) ) ; for ( int i = 0 ; i < s . length ( ) ; i ++ ) { dos . writeChar ( s . charAt ( i ) ) ; } }
target:  Outputs a string to the given stream.