diff --git a/c#/StringHas.cs b/c#/StringHas.cs new file mode 100644 index 0000000000000000000000000000000000000000..f745f0ccfedb3c5632542cc739f688b11e472dd8 --- /dev/null +++ b/c#/StringHas.cs @@ -0,0 +1,36 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading; +using System.Threading.Tasks; + +namespace C_Sharp +{ + public class StringHas + { + + /// + /// 错误判断 + /// + /// + /// + private bool StringHasF(string str) + { + if (str==null&&str=="") + { + return false; + } + return true; + } + /// + /// 正确的判断 + /// + /// + /// + private bool StringHasT(string str) + { + return string.IsNullOrEmpty(str); + } + + } +} \ No newline at end of file