ln this paper,the method of genetic programming is adopted to solve graph searching. This paper gives the searching method based on genetic programming,designs a new direction index. Then the terminals set and functions set of functions and automatically defined functions are defined,and thev satisfy the closure requirement.In addition this paper deduces the computation method of genetic programming ope rator represented as matrix of graph and gives the corespondent form ula. This WOrk COntributes much to the promotion and dissemination of solution of graph searching by application of genetic programming,and to the realization of the method of genetm programming through using normal advanced language