Abstract
The modular group Gamma = PSL(2, Z) is isomorphic to the free product of two cyclic groups of orders 2 and 3. In this paper, we give a necessary and sufficient condition for the existence of elliptic and parabolic elements in Gamma with a given cusp point. Then we give an algorithm to obtain such elements in words of generators using continued fractions and paths in the Farey graph.