调用匿名函数的骚操作
问:如何将1输出: function(){console.log(1)}()
答:
- (function(){console.log(1)}())
- 1,function(){console.log(1)}()
- +function(){console.log(1)}()
- -function(){console.log(1)}()
- ~function(){console.log(1)}()
- !function(){console.log(1)}()
- new function(){console.log(1)}()
- 0function(){console.log(1)}()