using System;
using System.Text;
class EncoderExample {
public static void Main() {
// Unicode characters.
Char[] chars = new Char[] {
'\u03a3' // Sigma
};
Encoder uniEncoder = Encoding.Unicode.GetEncoder();
int byteCount = uniEncoder.GetByteCount(chars, 0, chars.Length, true);
Console.WriteLine(byteCount);
}
}