@@ -0,0 +1,680 @@
+import java.util.Scanner;%0A%0Apublic class Main %7B%0A%0A    public static void main(String%5B%5D args) %7B%0A%0A        Scanner sc = new Scanner(System.in);%0A%0A        while (sc.hasNext()) %7B%0A%0A            long num = sc.nextLong();%0A            int%5B%5D%5B%5D triangle = new int%5B10%5D%5B10%5D;%0A%0A            for (int i = 9; i %3E= 0; i--) %7B%0A%0A                triangle%5B0%5D%5Bi%5D = (int) (num %25 10);%0A                num /= 10;%0A%0A            %7D%0A%0A            for (int i = 0; i %3C 9; i++) %7B%0A%0A                for (int j = 0; j %3C 9 - i; j++) %7B%0A%0A                    triangle%5Bi + 1%5D%5Bj%5D = (triangle%5Bi%5D%5Bj%5D + triangle%5Bi%5D%5Bj + 1%5D) %25 10;%0A%0A                %7D%0A%0A            %7D%0A%0A            System.out.println(triangle%5B9%5D%5B0%5D);%0A%0A        %7D%0A%0A    %7D%0A%0A%7D%0A

Create : 0062