浏览代码

Create an custom 'and' opeartor

With pattern matching
DricomDragon 5 年之前
父节点
当前提交
1e4130bab9
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      logic.hs

+ 4 - 0
logic.hs

@@ -0,0 +1,4 @@
+myAnd b1 b2 = 
+	case (b1, b2) of
+	(True, True) -> True
+	(_, _) -> False