Scala模式匹配 匹配常量、类型、数组、列表、元组,匹配元组扩展、匹配对象及样例类,偏函数_scala case array()-CSDN博客

网站介绍:文章浏览阅读428次。目录匹配常量、类型、数组、列表、元组、匹配元组扩展匹配对象及样例类偏函数匹配常量、类型、数组、列表、元组、匹配元组扩展package chapter08object Test01_PatternMatchBase { def main(args: Array[String]): Unit = { //1.基本定义语法 val x:Int=2 val y:String=x match { case 1=>"one"......_scala case array()