任何人都知道这是怎么回事我有代码
console.log('cCP: '+chatCurrentPlace+' - key: '+key);
if(key>chatCurrentPlace){chatCurrentPlace=key;}
console.log('cCP: '+chatCurrentPlace+' - key: '+key);
和控制台日志
cCP: 0 - key: 4
cCP: 4 - key: 4
cCP: 4 - key: 7
cCP: 7 - key: 7
cCP: 7 - key: 8
cCP: 8 - key: 8
cCP: 8 - key: 9
cCP: 9 - key: 9
cCP: 9 - key: 11
cCP: 9 - key: 11
为什么最后一个不起作用?它应该是 cCP: 11 - key: 11