def tekaTekiTeko( batas) :
if not isinstance ( batas, int ) or batas < 20 :
raise ValueError ( "Parameter harus bilangan bulat positif dan lebih dari 20" )
for i in range ( 1 , batas+1 ) :
if i % 2 == 0 and i % 3 == 0 and i % 5 == 0 :
print ( "TekaTekiTeko" )
elif i % 2 == 0 and i % 3 == 0 :
print ( "TekaTeki" )
elif i % 2 == 0 and i % 5 == 0 :
print ( "TekaTeko" )
elif i % 3 == 0 and i % 5 == 0 :
print ( "TekiTeko" )
elif i % 2 == 0 :
print ( "Teka" )
elif i % 3 == 0 :
print ( "Teki" )
elif i % 5 == 0 :
print ( "Teko" )
else :
print ( i)
if __name__ == "__main__" :
tekaTekiTeko( 30 )
ZGVmIHRla2FUZWtpVGVrbyhiYXRhcyk6CiAgICBpZiBub3QgaXNpbnN0YW5jZShiYXRhcywgaW50KSBvciBiYXRhcyA8IDIwOgogICAgICAgIHJhaXNlIFZhbHVlRXJyb3IoIlBhcmFtZXRlciBoYXJ1cyBiaWxhbmdhbiBidWxhdCBwb3NpdGlmIGRhbiBsZWJpaCBkYXJpIDIwIikKICAgIGZvciBpIGluIHJhbmdlKDEsIGJhdGFzKzEpOgogICAgICAgIGlmIGkgJSAyID09IDAgYW5kIGkgJSAzID09IDAgYW5kIGkgJSA1ID09IDA6CiAgICAgICAgICAgIHByaW50KCJUZWthVGVraVRla28iKQogICAgICAgIGVsaWYgaSAlIDIgPT0gMCBhbmQgaSAlIDMgPT0gMDoKICAgICAgICAgICAgcHJpbnQoIlRla2FUZWtpIikKICAgICAgICBlbGlmIGkgJSAyID09IDAgYW5kIGkgJSA1ID09IDA6CiAgICAgICAgICAgIHByaW50KCJUZWthVGVrbyIpCiAgICAgICAgZWxpZiBpICUgMyA9PSAwIGFuZCBpICUgNSA9PSAwOgogICAgICAgICAgICBwcmludCgiVGVraVRla28iKQogICAgICAgIGVsaWYgaSAlIDIgPT0gMDoKICAgICAgICAgICAgcHJpbnQoIlRla2EiKQogICAgICAgIGVsaWYgaSAlIDMgPT0gMDoKICAgICAgICAgICAgcHJpbnQoIlRla2kiKQogICAgICAgIGVsaWYgaSAlIDUgPT0gMDoKICAgICAgICAgICAgcHJpbnQoIlRla28iKQogICAgICAgIGVsc2U6CiAgICAgICAgICAgIHByaW50KGkpCgoKaWYgX19uYW1lX18gPT0gIl9fbWFpbl9fIjoKICAgIHRla2FUZWtpVGVrbygzMCkK