I\'d like to write an extension method to the String class so that if the input string to is longer than the provided length N, only the first
String
N
public static string TruncateLongString(this string str, int maxLength) { return str.Length <= maxLength ? str : str.Remove(maxLength); }