using System;
using System.Text;
class DecoderExample {
public static void Main() {
Byte[] bytes = new Byte[] {5, 0, 10, 0, 105, 0, 99, 0, 111, 0, 100, 0, 101, 0};
Decoder uniDecoder = Encoding.Unicode.GetDecoder();
int charCount = uniDecoder.GetCharCount(bytes, 0, bytes.Length);
Console.WriteLine("{0} characters needed to decode bytes.", charCount);
}
}