import java.util.Scanner fun main(args: Array<String>) { fun max(a:Int, b:Int) = Math.max(a, b) val read = Scanner(System.`in`) val res = read.nextLine() var max = 0 for (i in res.indices) { max = max(max, getLongest(res, i, i)) max = max(max, getLongest...