调用像这样的javascript方法是否正确
var flag = this.totalSubarrayLengths([ document.getElementsByTagName('ol'), document.getElementsByTagName('ul') ])
var totalSubarrayLengths = function(container) {
total = 0;
for (var val in container) {
var total += val.length;
}
return total;
}