怎样把这个代码链接起来按步骤运行?

id("mu").findOne().children().forEach(child => {
var target = child.findOne(id("a1l"));
target.click();
});

sleep(200);
id("mu").findOne().children().forEach(child => {
var target = child.findOne(id("aec"));
target.click();
});