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.
- Prepare
- Java
- Introduction
- Java Loops II
- Discussions
Java Loops II
Java Loops II
Sort by
recency
|
3175 Discussions
|
Please Login in order to post a comment
Easiest solution to the question. Juste understand the series and develop the formula i. e. Tn = a+b(2^n -1) . Now solve it easily :)
} `
public static void main(String[] args) throws IOException { int[][] mint=new int[100][3];
import java.util.; import java.io.;
class Solution{ public static void main(String []args){ Scanner in = new Scanner(System.in); int t=in.nextInt(); for(int i=0;iorder(a,b,n); } in.close(); } static void order(int a,int b,int n){ int sum=a+(1*b); System.out.print(sum+" "); int c=2; for(int i=1;i System.out.println(); } }
class Solution{
}