13 lines
292 B
Kotlin
13 lines
292 B
Kotlin
import java.io.*
|
|
|
|
public class C {
|
|
throws(javaClass<IOException>())
|
|
fun foo() {
|
|
FileInputStream("foo").use { input ->
|
|
FileOutputStream("bar").use { output ->
|
|
output.write(input.read())
|
|
output.write(0)
|
|
}
|
|
}
|
|
}
|
|
} |