Question:You have recently completed the creation of a new application.
Certkiller .com requires you to ensure that this new application creates a file that contains an
array of bytes.
What should you do? - (VB.NET) 

A Use the following code:
Public Sub WriteBytes(bytes As Byte())
Dim fs As New FileStream("C:\file.txt", FileMode.Create)
For i As Integer = 0 To bytes.Length - 2
fs.Write(bytes(i))
Next
fs.Close()
End Sub 

B Use the following code:
Public Sub WriteBytes(bytes As Byte())
Dim fs As New FileStream("C:\file.txt", FileMode.Create)
For i As Integer = 0 To bytes.Length - 2
fs.WriteByte(bytes(i))
Next
fs.Close()
End Sub 

C Use the following code:
Public Sub WriteBytes(bytes As Byte())
Dim fs As New FileStream("C:\file.txt", FileMode.Create)
fs.WriteByte(bytes, 0, bytes.Length)
fs.Close()
End Sub 

D Use the following code:
Public Sub WriteBytes(bytes As Byte())
Dim fs As New FileStream("C:\file.txt", FileMode.Create)
fs.Write(bytes, 0, bytes.Length)
fs.Close()
End Sub 

+ Answer
+ Report
Total Preview: 912

Copyright © 2024. Powered by Intellect Software Ltd