证一般
Cross product of 2 sets in Scala
val cross = (for (x<-setA; y<-setB) yield (x,y)) val cross2 = (setA flatMap (x => setB map ((x,_)))[详细]
2022-12-28 04:30 分类:问答
val cross = (for (x<-setA; y<-setB) yield (x,y)) val cross2 = (setA flatMap (x => setB map ((x,_)))[详细]