Text this: Logic Based Program Synthesis and Transformation