Right now, I have to take that piece of code and replicate it everywhere I want in my larger file.
现在我要把这段代码,复制到,大文件中的各个部分。
I keep seeing addition and I keep just copying my code, copying my code.
我总是看到加法,我一直复制我的代码,复制代码。
When you copy a dictionary, for example.
比方说当你复制一个代码词典的时候。
to do sqrt, or square root-- no, I'm going to square root use sqrt, that's the name I'm using here-- square root a hundred different places in some piece of code. Without function, I'd have to copy that piece of code everywhere.
让我做一下准备,想象一下我要调用sqrt或者-,不,我会调用sqrt函数,这是我在这里用的名字,我得把这段代码到处复制。
应用推荐