Could you please give algorithm for printing pascal triangle when an input number is taken which defines number of lines of pascal triangle that it has to print..

don't give me the code directly .. but help me how to crack it...