Find the flag in desicion tree(ML)

check out these code
check here