might be faster, might be slower, like check.py but with buttons, can't get correct end index, for now use check.py if you can