Hugo - added first step for ray casting to work - converting a list to a list of pairs