Posted: 13.11.2010 19:06
This is my code on creating pascals triangle. I know it gets no where, but thats where I need help. private static int[] nextRow(int []row) int x = 0; //length row = new int[x]; row[0] = 1; return row; This is my main which I will be using to test my code. package package04B; public class PascalsTriMain /** * @param args */ public static void main(String[] args) // TODO Auto-generated method stub System.out.println(\" Pascal's Triangle printed by \" + PascalsTri.getAuthor()); PascalsTri.printTri(10); System.out.println(); PascalsTri.printTri(15); I need help on starting with the first row which is 1 and taking this previous row to create the next row and then loop itself. Thanks