Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

初試此法,用「書之」之不解 #688

Open
lumingxijian opened this issue Feb 9, 2023 · 2 comments
Open

初試此法,用「書之」之不解 #688

lumingxijian opened this issue Feb 9, 2023 · 2 comments

Comments

@lumingxijian
Copy link

吾有一術。名之曰「乾者」。是術曰。
吾有一言。曰「「乾者乾也」」。名之曰「乾」。
乃得「乾」者。
是謂「乾者」之術也。

施「乾者」。
加「「」」於「「」」者。書之。

var 乾者 = _ => {}
乾者 = () => {
var 乾 = "乾者乾也"
return 乾
}
const _ans1 = 乾者()
const _ans2 = "" + ""
console.log(_ans1, _ans2)

果:乾者乾也

吾以為「書之」當書「」者。譯時卻做「乾者乾也」。蓋書之書「乾者」之術。私以爲誤也

@lumingxijian
Copy link
Author

若以

吾有一術。名之曰「乾者」。是術曰。
為是二遍。
吾有一言。曰「「乾者乾也」」。書之。
云云。
是謂「乾者」之術也。
施「乾者」。
加「「」」於「「」」者。書之。

則得

var 乾者 = _ => {}
乾者 = () => {
for (let _rand1 = 0; _rand1 < 2; _rand1++) {
console.log("乾者乾也")
}
}
const _ans2 = 乾者()
const _ans3 = "" + ""
console.log(_ans2, _ans3)

果: 乾者乾也
乾者乾也
undefined

@YuRen-tw
Copy link
Contributor

YuRen-tw commented Feb 9, 2023

文言
施「乾者」 []
┃吾有一言曰『乾也』、名之曰「乾」 乾 = "乾也" []
┗乃得「乾」者 _1 = 乾 []
堆 ← _1 [ "乾也" ]
加『』於『』者 _2 = "" + "" [ "乾也" ]
堆 ← _2 [ "乾也" , "" ]
書之 log(...堆) [] "乾也" ""
文言
施「乾者」 []
┃吾有一言曰『乾也』 堆 ← "乾也" [ "乾也" ]
┃書之 log(...堆) [] "乾也"
┃吾有一言曰『乾也』 堆 ← "乾也" [ "乾也" ]
┃書之 log(...堆) [] "乾也"
_2 = undefined []
堆 ← _2 [ undefined ]
加『』於『』者 _3 = "" + "" [ undefined ]
堆 ← _3 [ undefined , "" ]
書之 log(...堆) [] undefined ""

見:Stack-based way to nest function calls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants