We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Scanner obj = new Scanner(System.in);
int t1= obj.nextInt();
int t2 = obj.nextInt();
int t3 = obj.nextInt();
// int k = obj.nextInt();
int d=t3+t1+t2;
int x=3;
int[] a = new int[100000];
for(int i=5;i<100000;i++)
{
a[i] = d;
t1=t2;
t2=t3;
t3=d;
Project Euler #225: Tribonacci non-divisors
You are viewing a single comment's thread. Return to all comments →
Scanner obj = new Scanner(System.in); int t1= obj.nextInt(); int t2 = obj.nextInt(); int t3 = obj.nextInt(); // int k = obj.nextInt(); int d=t3+t1+t2; int x=3; int[] a = new int[100000]; for(int i=5;i<100000;i++) { a[i] = d; t1=t2; t2=t3; t3=d;
What's wrong in this?