Download as txt, pdf, or txt
Download as txt, pdf, or txt
You are on page 1of 1

import java.io.

*
import java.math.*
import java.security.*
import java.text.*
import java.util.*
import java.util.concurrent.*
import java.util.function.*
import java.util.regex.*
import java.util.stream.*
import kotlin.collections.*
import kotlin.comparisons.*
import kotlin.io.*
import kotlin.jvm.*
import kotlin.jvm.functions.*
import kotlin.jvm.internal.*
import kotlin.ranges.*
import kotlin.sequences.*
import kotlin.text.*

/*
* Complete the 'printNonVowels' function below.
*
* The function accepts STRING str as parameter.
*/

fun printNonVowels(str: String): Unit {


for (i in 0..(str.length-1)) {
if(str[i] !='a' && str[i] !='e' && str[i] !='i' && str[i] !='o' && str[i] !
='u'){
print(str[i] + "\n")
}
}
}

fun main(args: Array<String>) {


val str = readLine()!!

printNonVowels(str)
}

You might also like