Write a solution strategy for arranging three numbers in ascending order of their values. draw a flowchart for the same.
Answers
Answered by
5
Answer:
import java.util.*;
public class Main
{
public static void main(String[] args) {
ArrayList<Integer> list = new ArrayList<Integer>();
int x = 5 , y = 127 , z = -8;
list.add(x);
list.add(y);
list.add(z);
int max = Collections.max(list);
System.out.println("The largest number is " + max);
}
}
Explanation:
Similar questions
Computer Science,
2 days ago
Physics,
2 days ago
World Languages,
4 days ago
Math,
8 months ago
Computer Science,
8 months ago