is_somewhat_no

Function is_somewhat_no 

Source
pub fn is_somewhat_no(string: impl Display) -> bool
Expand description

Determines if a value is somewhat no.

Returns true when the value is something in the trend of "really n", "wow so n", very false, rawrr~ no ;3, contains n here.

ยงExamples

input should be somewhat no:

assert!(yn::is_somewhat_no("no")); // no is still somewhat no
assert!(yn::is_somewhat_no("really n"));
assert!(yn::is_somewhat_no("wow so n"));
assert!(yn::is_somewhat_no("very false"));
assert!(yn::is_somewhat_no("1 but is actually 0!"));
assert!(yn::is_somewhat_no("contains n here"));

should definitely not be somewhat no:

assert!(!yn::is_somewhat_no("yes"));
assert!(!yn::is_somewhat_no("very yes"));