fun main(arr: Array<String>) {
    val weekday = listOf("SUN","MON","TUE","WED","THU","FRI","SAT").let { it+it }
    val s = readLine()!!
    var ans = weekday.drop(weekday.indexOf(s) + 1).indexOf("SUN") + 1
    println(ans)
}
