began a* algorithm