我是 js 新手,我无法解决这个问题。
test("splice", function() {
var daysOfWeek = ['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday', 'Sunday'];
var workingWeek = daysOfWeek.splice(__);
ok(workingWeek.equalTo([__]), 'what is the value of workingWeek?');
ok(daysOfWeek.equalTo([__]), 'what is the value of daysOfWeek?');
});
我的尝试在下面,但它不起作用。
test("splice", function() {
var daysOfWeek = ['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday', 'Sunday'];
var workingWeek = daysOfWeek.splice(5,6);
ok(workingWeek.equalTo([5]), 'what is the value of workingWeek?');
ok(daysOfWeek.equalTo([2]), 'what is the value of daysOfWeek?');
});
有人可以为我提供任何线索吗?