Write an infinite loop using do while condition.
import java.util.*;
public class Solutions {
public static void main(String args[]) {
do {
} while(true);
}
}
Write an infinite loop using do while condition.
import java.util.*;
public class Solutions {
public static void main(String args[]) {
do {
} while(true);
}
}
Take an array of Strings input from the user & find the cumulative (combined) length of all those strings.
Find the maximum & minimum number in an array of integers.
[HINT : Read about Integer.MIN_VALUE & Integer.MAX_VALUE in Java]
Two numbers are entered by the user, x and n. Write a function to find the value of one number raised to the power of another i.e. x^n.