using System;
using System.Text;
public class Program
{
public static void Main()
StringBuilder sb = new StringBuilder();
sb.Append("Hello");
// The capacity of current object is 16 and length is 5 characters. Let’s set the capacity less than the current length of the StringBuilder.
sb.Capacity = 2; // throw exception
}