help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

The different results obtained by apply function.


From: Hongyi Zhao
Subject: The different results obtained by apply function.
Date: Thu, 7 Oct 2021 10:46:33 +0800

I try to reproduce the results given here [1], as follows:

(mapcar 'list '((1 2)(3 4))) ;; (((1 2)) ((3 4)))

(funcall 'mapcar 'list '((1 2)(3 4))) ;; (((1 2)) ((3 4)))

(apply 'mapcar 'list '((1 2)(3 4)) ()) ;; (((1 2)) ((3 4)))

The last one is different from the one given on the URL above:

(apply 'mapcar 'list '((1 2)(3 4))) ;; ((1 3) (2 4))

[1] https://stackoverflow.com/a/68876647

Any hints for this?
-- 
Assoc. Prof. Hongyi Zhao <hongyi.zhao@gmail.com>
Theory and Simulation of Materials
Hebei Vocational University of Technology and Engineering
No. 473, Quannan West Street, Xindu District, Xingtai, Hebei province



reply via email to

[Prev in Thread] Current Thread [Next in Thread]