Капча
/**
* Капча
*/
function capcha () {
var a=Math.floor(Math.random() * (10 - 0 + 1)) + 0;
var b=Math.floor(Math.random() * (10 - 0 + 1)) + 0;
var c=a+b;
d=prompt('Сколько будет '+a+'+'+b+'=?');
if (d==c) {
return true;
}
else {
alert('Не верный ответ');
return false;
}
}