' *** RINSTR.GFA *** ' ' *** RINSTR misses a character in the string if you start looking there ' *** GFA 3.07 & 3.5E ' CLS ' a$="12345" b$="3" PRINT PRINT " Two strings are declared:" PRINT " a$ = ""12345""" PRINT " b$ = ""3""" PRINT PRINT " Let's search for b$ in a$ with RINSTR:" PRINT " RINSTR(a$,b$) = ";RINSTR(a$,b$);" ! found it, OK" PRINT " RINSTR(a$,b$,5) = ";RINSTR(a$,b$,5);" ! found it, OK" PRINT " RINSTR(a$,b$,2) = ";RINSTR(a$,b$,2);" ! not found, OK" PRINT " RINSTR(a$,b$,3) = ";RINSTR(a$,b$,3);" ! bug, ""3"" on position 3 missed" PRINT " RINSTR(a$,b$,4) = ";RINSTR(a$,b$,4);" ! start looking to the right: OK" PRINT PRINT " It's safe to use RINSTR without start-position. If you do use a start-position,"; PRINT " it's necessary to add one to the intended position, or you will miss the" PRINT " character if it happens to be on the start-position itself." ' ~INP(2) CLS