Prefix has been removed from the code.
The solution produced is not the best but is manageable for time being.