Result

AC

Duration

5150ms

Code [DL]

fun r()=readLine()!!.toInt()-2
fun main(){var h=r()
var w=r()
for(c in "*${" ".repeat(h)}*")println("*${"$c".repeat(w)}*")}

stdin

28
28

stdout

****************************
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
*                          *
****************************

stderr