My solution for SBSTR1 is able to produce the correct solutions locally with beef 1.0.2, but on SPOJ I consistently get TLE. I downloaded and compiled bff 1.0.7 (SPOJ uses 1.0.6), and found the program hangs when interpreting my solution.
I suspect there is a bug in bff. Searching through the forum I found similar prior reports regarding to bff bugs. It would be great if spoj could provide beef as an alternative.