Which statement(s) is/are incorrect in relation to the two functions below? 1. public static byte[] ReadFully(Stream input) { byte[] buffer = new byte[16*1024]; using (MemoryStream ms = new MemoryStream()) { int read; while ((read = input.Read(buffer, 0, buffer.Length)) > 0) { ms.Write(buffer, 0, read); } return ms.ToArray(); } } 2. public static byte[] ReadFully(Stream input) { using (MemoryStream ms = new MemoryStream()) { input.CopyTo(ms); return ms.ToArray(); } }
Correct Answer: #1 can be used in all versions of the .NET Framework, while #2 is only supported in the .NET Framework 4.0 and above.
Explanation:
Note: This Question is unanswered, help us to find answer for this one
More C# MCQ Questions