Find A List Of Strings Inside String Scala

[Solved] Find A List Of Strings Inside String Scala | Scala - Code Explorer | yomemimo.com
Question : find a list of strings inside string scala

Answered by : xenophobic-xenomorph-tyzvetbbcynk

val a = "some random test message"
val keys = List("hi","random","test")
keys.exists(a.contains)

Source : https://stackoverflow.com/a/16046198/9564635 | Last Update : Mon, 04 Jul 22

Answers related to find a list of strings inside string scala

Code Explorer Popular Question For Scala