Help with this plz

 

setInterval(keyCheck, 1000);
function keyCheck() {
 if (Key.isDown(74) and Key.isDown(77) and Key.isDown(70)) {
  trace("test");
 }
}

 

can some1 plz tell if should work and if not how i can fix it with the desired effect (i would like to see if the J & M & F keys are being hit at the same time, and if so trace “test”, well actually i want to go to another frame but thats easy)