I have a function that returns two integers as a list. Is it possible in Java to separate these into individual int variables from the function?
int first, int second = returnsIntList();
Or am I restricted to initializing.
int numbers[] = returnsIntList();
int firstInt = numbers[0];
int secondInt = numbers [1];
I'm trying to increase readability in my program since the two integers can't be described with a single word but I'm unsure if the syntax exists after searching because 90% of the battle with searching these days is knowing the correct terms to search.