Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
4
Task/Arrays/Common-Lisp/arrays-1.lisp
Normal file
4
Task/Arrays/Common-Lisp/arrays-1.lisp
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
(let ((array (make-array 10)))
|
||||
(setf (aref array 0) 1
|
||||
(aref array 1) 3)
|
||||
(print array))
|
||||
5
Task/Arrays/Common-Lisp/arrays-2.lisp
Normal file
5
Task/Arrays/Common-Lisp/arrays-2.lisp
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
(let ((array (make-array 0 :adjustable t :fill-pointer 0)))
|
||||
(vector-push-extend 1 array)
|
||||
(vector-push-extend 3 array)
|
||||
(setf (aref array 0) 2)
|
||||
(print array))
|
||||
1
Task/Arrays/Common-Lisp/arrays-3.lisp
Normal file
1
Task/Arrays/Common-Lisp/arrays-3.lisp
Normal file
|
|
@ -0,0 +1 @@
|
|||
(make-array 10)
|
||||
1
Task/Arrays/Common-Lisp/arrays-4.lisp
Normal file
1
Task/Arrays/Common-Lisp/arrays-4.lisp
Normal file
|
|
@ -0,0 +1 @@
|
|||
(make-array '(10 20))
|
||||
4
Task/Arrays/Common-Lisp/arrays-5.lisp
Normal file
4
Task/Arrays/Common-Lisp/arrays-5.lisp
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
; Makes an array of 20 objects initialized to nil
|
||||
(make-array 20 :initial-element nil)
|
||||
; Makes an integer array of 4 elements containing 1 2 3 and 4 initially which can be resized
|
||||
(make-array 4 :element-type 'integer :initial-contents '(1 2 3 4) :adjustable t)
|
||||
Loading…
Add table
Add a link
Reference in a new issue