基本在一个独立代码开始都写: Clear["Global`*"] (*Clear all variables*) 就可以了 转载于:https://www.cnblogs.com/zhangbo2008/p/8288943.html