30秒学会 C# 片段 – IsNotA
Returns true if the given object is not of the specified type, false otherwise. Use the is operator ...
Returns true if the given object is not of the specified type, false otherwise. Use the is operator ...
Replaces all but the last n characters in a string with the specified mask character. Use string.Sub...
Decapitalizes the first letter of a string. Use string.ToCharArray() to convert the string to an arr...
Returns true if the given object is of the specified type, false otherwise. Use the is operator to c...
Converts a string to camel case. Use Regex.Matches() with an appropriate regular expression to break...
Returns the head of a collection. Use IEnumerable.Count() to check if the enumerable is non-empty. U...
Splits a multiline string into an array of lines. Use string.Split() with all forms of the newline s...
Pads a given number to the specified length. Use Int32.ToString() with an appropriate format specifi...
Returns the type of the given object. Use typeof() on the given object’s type.
Finds the median of a list of numbers. Use the params keyword to accept either an array or a variabl...