seperating logic