This method is used to return a value indicating whether this instance is equal to a specified Boolean object.
public bool Equals (bool obj);
Here, obj is a boolean value to compare to this instance.
Return Value: This method returns true if obj has the same value as this instance otherwise it returns false.
Below programs illustrate the use of Boolean.Equals(bool obj) Method:
True is equal to True True is not equal to False False is not equal to True False is equal to False
input1 is not equal to input2
Note: This method implements the
System.IEquatable<T> interface, and performs slightly better than Equals because it does not have to convert the obj parameter to an object.