how to convert 2d array into 1d?
问题 i have a code that create 2d array using user input and it work fine but now i have 2 questions the first one: how to convert 2d array to 1d array? second question: how to choose or trace the elements above the right diagonal in the 2d array? anyone can help me to fix this code? this my code package question3; import java.util.Arrays; import java.util.Collection; import java.util.Scanner; public class Array2d { public static void main(String[] args) { int[][] matrix = new int[3][3]; int[]