使用Inputstream輸入流讀取數據的時候總要使用一個額byte[]數組進行讀取

byte[] b= new byte[1024];

while((len = in.read(b)) != -1) {
      out.write(b, 0, len);      
     }

 

while((len = in.read()) != -1) {
      out.write(b, 0, len);      
     }

如果不寫入b數組中,讀取的內容大出來十幾倍