add solution for one step a* algorithm