This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* array 转 list | |
Arrays.asList(T... elem) 返回的是Arrays内部自己实现的List. | |
*/ | |
public void arrayToList(){ | |
int[] array = new int[10]; | |
List<Integer> lists = new ArrayList<Integer>(Arrays.asList(array)); | |
} | |
/*Integer array to int array | |
不会自动装箱,也 无法强转. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;Scheme中关于list的操作. | |
; author: cyanlong | |
; date: 2016-11-02 | |
;一:构造list | |
;通过Scheme提供的序对操作. | |
;cons :construct | |
(cons 1 | |
(cons 2 | |
(cons 3 nil))) |