finished backtracking
added a little bit of doc