Generally speaking, in the e-learning systems, a course is modeled as a graph, where each node represents a knowledge node (KU) and two nodes are connected to form a semantic network. The desired knowledge is provided by the student as a direct request or from search results, mapping the owned knowledge onto the target knowledge. How to select a learning path which costs the least time and effort is critical. In this paper, we described the relationships between different nodes in the graph structure of knowledge units and propose an algorithm to select the shortest learning paths to learn the target knowledge.