零件内部功能的行为 [英] Behavior of Part inside Function
本文介绍了零件内部功能的行为的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
下面给出了一些奇怪的部分"警告
<前>清除[f];f = 函数[{x}, x[[1]] == x[[2]]]但是,如果我再次执行第二行,它会在没有警告的情况下工作,知道发生了什么吗?
解决方案
您确定吗?我在 7.0.1 版中没有看到任何警告:
In[1]:= Clear[f];f=函数[{x},x[[1]]==x[[2]]]输出[2]=函数[{x},x[[1]]==x[[2]]]
The following gives some strange "Part" warnings
Clear[f]; f = Function[{x}, x[[1]] == x[[2]]]
However if I execute the second line again, it works without warnings, any idea what's going on?
解决方案
Are you sure? I don't see any warnings in version 7.0.1:
In[1]:= Clear[f];
f=Function[{x},x[[1]]==x[[2]]]
Out[2]= Function[{x},x[[1]]==x[[2]]]
这篇关于零件内部功能的行为的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文