Filing out the cases-----> dont work


why do i get this mesage when i press save and submit
"Oops, try again. Did you call the .animate() function on your $('img') for each of the three additional cases?"

this is my code, and its work, because Mario is moving in all direction!

$(document).ready(function() {
$(document).keydown(function(key) {
switch(parseInt(key.which,10)) {
// Left arrow key pressed
case 37:
$('img').animate({left: "-=10px"}, 'fast');
// Up Arrow Pressed
case 38:
$("img").animate({top:"-=10px"}, "fast");
// Right Arrow Pressed
case 39:
$("img").animate({left:"+=10px"}, "fast");
// Down Arrow Pressed
case 40:
$("img").animate({top:"+=10px"}, "fast");


Note the quotation marks in the example. Just in case the SCT is looking at these, it may be advisable to match yours to the example.


yes, you were right. But still, i was alwause thinking that sigle and double quotes are doing the same job!!!
Anyway, thanx man!!


Normally it shouldn't matter. In cases such as this where the lesson checker is examining our code as string content, exact match is all it can allow to pass. It's a small oversight on the part of the course author, but one we can live with once we know about it.