solution for the problem of pascal's triangle