separating code from repy