pascal triangle part II from leetcode updated