想币 想疯了
(defun extract-numeric-from-text (text)
(setq str-list (vl-string->list text)) ; 将字符串转换为字符列表
(setq num-list nil) ; 用于存储数字字符
(foreach char str-list
(if (and (>= char 48) (<= char 57)) ; 48 到 57 是数字 0 到 9 的 ASCII 码值
(setq num-list (append num-list (list char)))
(setq num-list (append num-list (list 32)))
)
)
(setq num-str (vl-list->string num-list)) ; 将数字字符列表转换回字符串
)
哈哈哈哈哈哈
页:
[1]