9. var retVal = for{
a <- numList if a != 3; if a < 8
}yield a
for( a <- retVal){
println( "Value of a: " + a );
}
val delimiter = if(defaultDelimiter)’;’ else ‘-’;
Noreturn any more!
54. what a route looks like
[Http Method] [path] [controller method]
GET / controllers.Application.main
POST / controllers.Application.index
# Map static resources from the /public folder to the /assets URL path
GET /assets/*file controllers.Assets.at(path="/public", file)
GET /webjars/*file controllers.WebJarAssets.at(file)
61. You know Scala Collections well, you
play with Spark well ;)
val textFile = spark.textFile("hdfs://...")
val errors = textFile.filter(line => line.contains("ERROR"))
errors.count()
errors.filter(line => line.contains("MySQL")).count()
errors.filter(line => line.contains("MySQL")).collect()