Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

turn int array to set java

import java.util.stream.Collectors;
// int[] nums = {1,2,3,4,5}
Set<Integer> set = Arrays.stream(nums).boxed().collect(Collectors.toSet())
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #turn #int #array #set #java
ADD COMMENT
Topic
Name
2+4 =