<html>
<head>
<title>Mister Ed Mathematics - RJM Programming - October, 2024</title>
<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=0.1, maximum-scale=8, user-scalable=yes" >
<style>
details { display: flex; }
table { font-size: 12px; }
td { background-image: linear-gradient(#f0f0f0, #f2f2f2, #f4f4f4, #f6f6f6, #f8f8f8, #fafafa); }
select { background-image: linear-gradient(#fff0f0, #fff2f2, #fff4f4, #fff6f6, #fff8f8, #fffafa); }
#actionsel { background-image: linear-gradient(#fff0ff, #fff2ff, #fff4ff, #fff6ff, #fff8ff, #fffaff); }
input[type=checkbox] { // thanks to https://stackoverflow.com/questions/2460501/how-to-change-checkboxs-border-style-in-css
-webkit-box-shadow: 0px 0px 0px 1px rgba(255,0,0,1);
-moz-box-shadow: 0px 0px 0px 1px rgba(255,0,0,1);
box-shadow: 0px 0px 0px 1px rgba(255,0,0,1);
}
button { background-image: linear-gradient(#f0f0ff, #f2f2ff, #f4f4ff, #f6f6ff, #f8f8ff, #fafaff); padding: 6 6 6 6; }
</style>
<script type='text/javascript'>
// Thanks to Behind Me Dips Eternity, by Emily Dickinson
// Thanks to https://sites.google.com/site/examplesinpoetry/sestet-poetry-example-definition
var operopts=[], jscore=0, jgoes=0, pans=2, ifactor=1;
var buttonp=0;
var numtype='';
var numtypes=[];
var saveuntil=2000;
var touches=[];
var wasscale=1.0, isscale=1.0;
var ote='';
var detsuffix='</summary>';
var blurbsuffix='</details>';
var detnum=0;
var noway=false;
var lastajax='', lasturl='', lasturls=[], waithere=false;
var idc=0, jdc=0;
var idfound=false;
var blurb='', rawhtml='';
var ilots=0;
var myxhr=null;
var thisa='';
var wos=[null, null, null, null, null, null];
var wosurl=['', '', '', '', '', ''];
var cindxs="button:0,td:1,tr:2,tbody:3,table:4,body:5";
var indxs=["button:0", "td:1", "tr:2", "tbody:3", "table:4", "body:5"];
var cols=["#f0f0f0", "#f2f2f2", "#f4f4f4", "#f6f6f6", "#f8f8f8", "#fafafa"];
// Thanks to https://bilingualkidspot.com/2018/04/23/popular-nursery-rhymes-for-kids-english/
var lotsofsix=["<br>O mistress mine, where are you roaming?;<br>It was many and many a year ago,;<br>Behind Me .. dips Eternity ..;<br>There was a farmer who had a dog,;<br>Five little ducks;<br>That well I deem each mountain, wood and plain,",
"O stay and hear! your true-love's coming ;In a kingdom by the sea,;Before Me .. Immortality ..;And Bingo was his name-O.;Went out one day;And river knows, what I from man conceal,",
"That can sing both high and low;That a maiden there lived whom you may know;Myself .. the Term between ..;B-I-N-G-O!;Over the hill and far away;What dreary hues my life's fond prospects dim.",
"Trip no further, pretty sweeting,;By the name of ANNABEL LEE;Death but the Drift of Eastern Gray,;B-I-N-G-O!;Mother duck said;Yet whate'er wild or savage paths I've ta'en,",
"Journey's end in lovers' meeting-- ;And this maiden she lived with no other thought;Dissolving into Dawn away,;B-I-N-G-O!;'Quack, quack, quack, quack.';Where'er I wander, love attends me still,",
"Every wise man's son doth know.;Than to love and be loved by me.;Before the West begin ..;And Bingo was his name-O!;But only four little ducks came back.;Soft whisp'ring to my soul, and I to him."];
function dalert() {
var thata='';
if (thisa != '') {
thata=thisa;
thisa='';
alert(thata);
}
}
function thisalert(inb) {
thisa=inb;
setTimeout(dalert, 4000);
}
function tableize(what) {
var dih=document.getElementById('results').innerHTML, trih='';
if (document.getElementById('results').innerHTML.indexOf('<table') == -1) {
what='<table cellpadding=20 cellspacing=20><tbody><tr id=mywhat><td>' + what + '</td></tr></tbody></table>';
} else if (!idfound) {
//alert('what=' + what + ' and ' + dih.replace('</tr>', '<td>' + what + '</td></tr>'));
if (1 == 1) {
trih=document.getElementById('mywhat').innerHTML;
//alert(": " + '<summary' + what.split('<summary')[1].split('</summary>')[0] + '</summary>');
//if (trih.indexOf('<summary' + what.split('<summary')[1].split('</summary>')[0] + '</summary>') == -1) {
// if (1 == 2) { alert('<summary' + what.split('<summary')[1].split('</summary>')[0] + '</summary> not found in ' + trih); }
//} else if (trih.replace('' + '<summary' + what.split('<summary')[1].split('</summary>')[0] + '</summary>','<summary></summary>') == trih.replace('' + '<summary' + what.split('<summary')[1].split('</summary>')[0] + '</summary>','<summary></summary>').replace(/\<td\>\<br\>\<br\>\<details[^>]+\>\<summary\>\<\/summary\>[^/]+\/details\>\<\/td\>/g, '')) {
// alert('<summary' + what.split('<summary')[1].split('</summary>')[0] + '</summary>' + ' ... did not find in ' + trih.replace('' + '<summary' + what.split('<summary')[1].split('</summary>')[0] + '</summary>','<summary></summary>'));
//}
//trih=trih.replace(/\<td\>\<br\>\<br\>\<details[^>]+\<summary\>\<\/summary\>[^/]+\/details\>\<\/td\>/g, '');
document.getElementById('mywhat').innerHTML='<td>' + what + '</td>' + trih.replace('' + '<summary' + what.split('<summary')[1].split('</summary>')[0] + '</summary>','<summary></summary>').replace(/\<td\>\<br\>\<br\>\<details[^>]+\<summary\>\<\/summary\>[^/]+\/details\>\<\/td\>/g, '');
trih=document.getElementById('mywhat').innerHTML;
if (trih != trih.replace(/\<td\>\<br\>\<br\>\<details[^>]+\>\<summary\>\<\/summary\>[^/]+\/details\>\<\/td\>/g, '')) {
trih=trih.replace(/\<td\>\<br\>\<br\>\<details[^>]+\>\<summary\>\<\/summary\>[^/]+\/details\>\<\/td\>/g, '');
document.getElementById('mywhat').innerHTML=trih;
}
//alert(document.getElementById('results').innerHTML);
} else {
document.getElementById('results').innerHTML=dih.replace('</tr>', '<td>' + what + '</td></tr>');
}
return '';
}
return what;
}
function delayedalert() {
console.log('Here at delayedalert ' + lasturls.length);
var ok=true;
for (var iii=0; iii<lasturls.length; iii++) {
ok=true;
jdc=iii;
for (var i=0; i<wosurl.length; i++) {
if (wosurl[i].indexOf(lasturls[iii]) != -1) { ok=false; }
}
if (ok) {
if (wos[jdc]) {
if (!wos[jdc].closed) {
wos[jdc].close();
}
}
wosurl[jdc]=lasturls[iii];
wos[jdc]=window.open(lasturls[iii], '_blank', 'top=' + eval(eval(-600 - jdc*10) + eval('' + screen.height)) + ',left=' + eval(eval(-600 - jdc*10) + eval('' + screen.width)) + ',width=600,height=600');
}
}
lasturls=[];
waithere=false;
}
function ouralert(ins) {
var ok=true;
if (ins == '' && lasturl != '') {
if (waithere) {
if (eval('' + lasturls.length) == 0) {
setTimeout(delayedalert, 5000);
lasturls.push(lasturl);
console.log('Pushed ' + lasturl);
} else {
lasturls.push(lasturl);
console.log('pushed ' + lasturl);
}
return '';
}
for (var i=0; i<wosurl.length; i++) {
if (wosurl[i].indexOf(lasturl) != -1) { ok=false; }
}
if (ok) {
if (wos[jdc]) {
if (!wos[jdc].closed) {
wos[jdc].close();
}
}
wosurl[jdc]=lasturl;
wos[jdc]=window.open(lasturl, '_blank', 'top=' + eval(eval(-600 - jdc*10) + eval('' + screen.height)) + ',left=' + eval(eval(-600 - jdc*10) + eval('' + screen.width)) + ',width=600,height=600');
}
//lasturl='';
} else {
if (wos[jdc]) {
if (!wos[jdc].closed) {
wos[jdc].close();
}
}
wos[jdc]=window.open('', '_blank', 'top=50,left=50,width=600,height=600');
wos[jdc].document.write(ins);
}
}
function stateChanged() {
if (myxhr.readyState == 4) {
if (myxhr.status == 200) {
console.log('myxhr=' + myxhr);
rawhtml = myxhr.response;
ouralert(rawhtml);
}
}
}
function ajaxit(parturl) {
myxhr = new XMLHttpRequest();
if (myxhr) {
if (1 == 11) {
myxhr.open('GET', '//www.thoughtco.com/search?q=' + encodeURIComponent(parturl), true);
myxhr.onreadystatechange=stateChanged;
myxhr.send(null);
} else if (1 == 1) {
if (lasturl != '//www.google.com/search?q=' + encodeURIComponent(parturl)) {
lasturl='//www.google.com/search?q=' + encodeURIComponent(parturl);
ouralert('');
}
} else {
var xurl = './getme.php';
var formis = new FormData();
if (myxhr) {
// https://www.google.com/search?q=mary+had&sxsrf=APwXEdd8WBBsDjbjGl2EFNFASHbQnV9rNw%3A1679888964273&source=hp&ei=RBIhZJntDqrK2roPy6KWwA0&iflsig=AOEireoAAAAAZCEgVHCla3RdkWinrVGkAaOlMAyaTEbX&ved=0ahUKEwiZn-eHmvv9AhUqpVYBHUuRBdgQ4dUDCAo&uact=5&oq=mary+had&gs_lcp=Cgdnd3Mtd2l6EAMyBAgjECcyBQgAEIAEMgUIABCABDIFCAAQgAQyBQgAEIAEMgUIABCABDIFCAAQgAQyBQgAEIAEMgUIABCABDIFCAAQgAQ6CwgAEIAEELEDEIMBOhEILhCABBCxAxCDARDHARDRAzoOCC4QigUQsQMQgwEQ1AI6CwguEIoFELEDEIMBOggILhCABBCxAzoOCC4QgAQQsQMQgwEQ1AI6CwgAEIoFELEDEIMBOgUILhCABDoLCC4QgAQQxwEQrwE6DgguEIAEELEDEMcBEK8BOgsILhCABBCxAxDUAjoRCC4QigUQsQMQgwEQxwEQrwE6CAgAEIAEELEDOggILhCABBDUAjoLCC4QgAQQsQMQgwFQAFjKDWCAD2gAcAB4AIABgwKIAdwLkgEFMC43LjGYAQCgAQE&sclient=gws-wiz
formis.append('q', 'http://www.google.com/search?q=' + encodeURIComponent(parturl));
myxhr.open('POST', xurl); //, true);
myxhr.onreadystatechange=stateChanged;
myxhr.send(formis);
}
}
}
}
function commonev(othis) {
//saveuntil=2000;
if (numtype == '') { numtype='' + event.type + ':' + ('' + event.target.outerHTML).substring(1).split(' ')[0].split('>')[0] + ':' + ('' + othis.outerHTML).substring(1).split(' ')[0].split('>')[0]; } else { numtype+=',' + event.type + ':' + ('' + event.target.outerHTML).substring(1).split(' ')[0].split('>')[0] + ':' + ('' + othis.outerHTML).substring(1).split(' ')[0].split('>')[0]; }
console.log('numtype=' + numtype + ' ' + ('' + new Date()));
numtypes=numtype.split(',');
if (saveuntil == 2000) { setTimeout(assesslater, 100); }
if (eval('' + jdc) >= eval('' + lotsofsix.length)) { jdc=0; }
jdc=Math.floor(Math.random() * lotsofsix.length);
if ((',' + cindxs + ',').indexOf(',' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ':') != -1) {
if (lastajax != lotsofsix[jdc].split(';')[eval((',' + cindxs + ',').split(',' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ':')[1].split(',')[0])].replace(/\<br\>/g, String.fromCharCode(10))) {
lastajax=lotsofsix[jdc].split(';')[eval((',' + cindxs + ',').split(',' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ':')[1].split(',')[0])].replace(/\<br\>/g, String.fromCharCode(10));
ajaxit(lotsofsix[jdc].split(';')[eval((',' + cindxs + ',').split(',' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ':')[1].split(',')[0])].replace(/\<br\>/g, String.fromCharCode(10)));
}
}
}
function ttlook() {
var tspecific=' pinch';
if (wasscale > isscale) {
tspecific=' Pinch';
} else if (isscale > wasscale) {
tspecific=' Spread';
} else if (eval('' + ote.split(':').length) >= 5) {
if (eval(ote.split(':')[1].split(',')[0].trim()) > eval(ote.split(':')[3].split(',')[0].trim())) {
if (eval(ote.split(':')[1].split(',')[1].split(' ')[0].trim()) <= eval(ote.split(':')[3].split(',')[1].split(' ')[0].trim())) {
tspecific=' spread';
}
} else if (eval(ote.split(':')[1].split(',')[0].trim()) < eval(ote.split(':')[3].split(',')[0].trim())) {
if (eval(ote.split(':')[1].split(',')[1].split(' ')[0].trim()) >= eval(ote.split(':')[3].split(',')[1].split(' ')[0].trim())) {
tspecific=' spread';
}
}
} else {
tspecific='';
}
document.getElementById('numbers').innerHTML='of touch' + tspecific + ' gesture ';
document.getElementById('numberst').innerHTML='of touch' + tspecific + ' gesture ';
//document.getElementById('numbers').innerHTML+=ote; //('(' + event.targetTouches.length + ') ' + event.targetTouches[0].clientX + ',' + event.targetTouches[0].clientY + ' to ' + event.targetTouches[1].clientX + ',' + event.targetTouches[1].clientY);
ote='';
}
function assesslater() {
var lrm=(' ' + buttonp).replace(' 0', ' left').replace(' 1', ' middle').replace(' 2', ' right');
console.log('lrm=' + lrm);
saveuntil-=100;
if (saveuntil > 0) {
setTimeout(assesslater, 100);
} else {
if (numtype.indexOf(',') != -1 || numtype.indexOf('touch') != -1) { // multiple event analysis
document.getElementById('numberst').innerHTML='';
var numtypeslength=numtypes.length;
for (var ii=0; ii<eval(-1 + numtypes.length); ii++) {
if (numtypes[eval(-1 + numtypes.length)] != numtypes[ii]) { numtypeslength--; }
}
//if (numtypes[0] == numtypes[1]) {
// document.getElementById('myh1').innerHTML+=' Multiple event ' + numtypes[0] + ' ' + ('' + new Date());
//}
if (numtypes[eval(-1 + numtypes.length)].indexOf('dblclick') != -1) {
if (numtypes[eval(-1 + numtypes.length)].split(':')[2] == numtypes[eval(-2 + numtypes.length)].split(':')[2]) {
document.getElementById('numbers').innerHTML='of programmed for double' + lrm + ' click';
} else {
document.getElementById('numbers').innerHTML='of quick programmed for propagated clicking';
}
} else if (numtypes[eval(-1 + numtypes.length)].indexOf('click') != -1) {
if (numtypes[eval(-1 + numtypes.length)] == numtypes[eval(-2 + numtypes.length)]) {
document.getElementById('numbers').innerHTML='of programmed for discrete ' + numtypeslength + 'x' + lrm + ' clicking';
} else if (numtypes[eval(-1 + numtypes.length)].split(':')[2] == numtypes[eval(-2 + numtypes.length)].split(':')[2]) {
document.getElementById('numbers').innerHTML='of programmed for' + lrm + ' click';
} else {
document.getElementById('numbers').innerHTML='of fast programmed for propagated clicking';
}
} else if (numtypes[eval(-1 + numtypes.length)].indexOf('contextmenu') != -1) {
if (numtypes[eval(-1 + numtypes.length)] == numtypes[eval(-2 + numtypes.length)]) {
document.getElementById('numbers').innerHTML='of programmed for discrete ' + numtypeslength + 'x' + (' right' + lrm).replace(' right right', ' right') + ' clicking';
} else if (numtypes[eval(-1 + numtypes.length)].split(':')[2] == numtypes[eval(-2 + numtypes.length)].split(':')[2]) {
document.getElementById('numbers').innerHTML='of programmed for' + (' right' + lrm).replace(' right right', ' right') + ' click';
} else {
document.getElementById('numbers').innerHTML='of fast programmed for propagated' + (' right' + lrm).replace(' right right', ' right') + ' clicking';
}
} else if (numtypes[eval(-1 + numtypes.length)].indexOf('auxclick') != -1) {
if (numtypes[eval(-1 + numtypes.length)] == numtypes[eval(-2 + numtypes.length)]) {
document.getElementById('numbers').innerHTML='of programmed for discrete ' + numtypeslength + 'x' + (' middle' + lrm).replace(' middle middle', ' middle') + ' clicking';
} else if (numtypes[eval(-1 + numtypes.length)].split(':')[2] == numtypes[eval(-2 + numtypes.length)].split(':')[2]) {
document.getElementById('numbers').innerHTML='of programmed for' + (' middle' + lrm).replace(' middle middle', ' middle') + ' click';
} else {
document.getElementById('numbers').innerHTML='of fast programmed for propagated' + (' middle' + lrm).replace(' middle middle', ' middle') + ' clicking';
}
} else if (numtypes[eval(-1 + numtypes.length)].indexOf('wheel') != -1) {
if (numtypes[eval(-1 + numtypes.length)] == numtypes[eval(-2 + numtypes.length)]) {
document.getElementById('numbers').innerHTML='of programmed for discrete ' + numtypeslength + 'x' + (' wheel' + lrm).replace(' wheel wheel', ' wheel').replace(' wheel left', ' wheel') + ' clicking';
} else if (numtypes[eval(-1 + numtypes.length)].split(':')[2] == numtypes[eval(-2 + numtypes.length)].split(':')[2]) {
document.getElementById('numbers').innerHTML='of programmed for' + (' wheel' + lrm).replace(' wheel wheel', ' wheel').replace(' wheel left', ' wheel') + ' click';
} else {
document.getElementById('numbers').innerHTML='of fast programmed for propagated' + (' wheel' + lrm).replace(' wheel wheel', ' wheel').replace(' wheel left', ' wheel') + ' clicking';
}
} else if (numtypes[eval(-1 + numtypes.length)].indexOf('mouseo') != -1) {
if (numtypes[eval(-1 + numtypes.length)] == numtypes[eval(-2 + numtypes.length)]) {
document.getElementById('numbers').innerHTML='of programmed for discrete ' + numtypeslength + 'x' + lrm + ' hovering';
} else if (numtypes[eval(-1 + numtypes.length)].split(':')[2] == numtypes[eval(-2 + numtypes.length)].split(':')[2]) {
document.getElementById('numbers').innerHTML='of programmed for' + lrm + ' hovering';
} else {
document.getElementById('numbers').innerHTML='of fast programmed for roaming type of' + lrm + ' hovering';
}
} else if (numtypes[eval(-1 + numtypes.length)].indexOf('touchend') != -1) {
ttlook();
document.getElementById('numberst').innerHTML=document.getElementById('numbers').innerHTML;
} else {
document.getElementById('numbers').innerHTML='';
document.getElementById('numberst').innerHTML='';
}
}
numtype='';
numtypes=[];
saveuntil=2000;
}
}
function moi(othis) {
var extras='';
var touchList = event.changedTouches;
var touch;
ifactor=1;
if (event.touches) {
if (eval('' + event.touches.length) > 1) {
document.getElementById('ians').value='' + event.touches.length;
ifactor=5;
checkans(document.getElementById('ians'));
}
}
return '';
switch ('' + event.type) {
case 'contextmenu':
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'auxclick':
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'wheel':
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'dblclick':
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'mouseover':
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'mousedown':
buttonp=eval(('0' + event.button).slice(-1));
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'mouseoout':
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'touchstart': // thanks to https://stackoverflow.com/questions/15240946/retrieving-touchstart-coordinates-in-a-touchend-event
try {
wasscale=eval('' + window.visualViewport.scale);
} catch(exgf) { wasscale=1.0; }
touchList = event.changedTouches;
for (var i = 0; i < touchList.length; i++) {
ote=("startX: " + touchList[i].screenX + "," + + touchList[i].screenY + " id: " + touchList[i].identifier + " ");
touch = {x: touchList[i].screenX, y: touchList[i].screenY, id: touchList[i].identifier};
touches.push(touch);
}
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
waithere=true;
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'touchdown':
buttonp=eval(('0' + event.button).slice(-1));
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
waithere=true;
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'touchend': // thanks to https://stackoverflow.com/questions/15240946/retrieving-touchstart-coordinates-in-a-touchend-event
try {
isscale=eval('' + window.visualViewport.scale);
} catch(exsgf) { isscale=1.0; }
touchList = event.changedTouches;
for (var i = 0; i < touchList.length; i++) {
touch = {x: touchList[i].screenX, y: touchList[i].screenY, id: touchList[i].identifier};
for (var j = touches.length - 1; j >= 0 ; j--) {
if (touches[j].id == touch.id) {
touches.splice(j, 1);
} else {
ote+=(" endX: "+ touches[j].x + "," + + touches[j].y + " id: " + touchList[i].identifier);
}
}
}
if (document.getElementById('mycbomo').checked && document.getElementById('eventtype').value == ('' + event.type)) {
waithere=true;
//ote=' huh ';
//try {
//ote+='(' + event.touches.length + ') ';
//} catch(etr) { }
//try {
//ote+='' + event.touches[0].clientX + ',' + event.touches[0].clientY + ' to ' + event.touches[1].clientX + ',' + event.touches[1].clientY;
//} catch(etrd) { }
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
commonev(othis);
}
break;
case 'click':
//saveuntil=2000;
if (document.getElementById('actionsel').value.indexOf('preventDefault') != -1) { event.preventDefault(); }
if (document.getElementById('actionsel').value.indexOf('stopPropagation') != -1) { event.stopPropagation(); }
if (document.getElementById('actionsel').value.indexOf('noonclick') == -1) {
if (numtype == '') { numtype='' + event.type + ':' + ('' + event.target.outerHTML).substring(1).split(' ')[0].split('>')[0] + ':' + ('' + othis.outerHTML).substring(1).split(' ')[0].split('>')[0]; } else { numtype+=',' + event.type + ':' + ('' + event.target.outerHTML).substring(1).split(' ')[0].split('>')[0] + ':' + ('' + othis.outerHTML).substring(1).split(' ')[0].split('>')[0]; }
console.log('numtype=' + numtype + ' ' + ('' + new Date()));
numtypes=numtype.split(',');
if (saveuntil == 2000) { setTimeout(assesslater, 100); }
//document.getElementById('myh1').innerHTML+=' ' + event.target.outerHTML.substring(1).split(' ')[0].split('>')[0];
if (('' + event.target.outerHTML).substring(1).split(' ')[0].split('>')[0] != 'button') {
if (eval('' + jdc) >= eval('' + lotsofsix.length)) { jdc=0; }
//alert('2967 ' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0]);
if ((',' + cindxs + ',').indexOf(',' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ':') != -1) {
//alert((',' + cindxs + ',').split(',' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ':')[1].split(',')[0] + ' ' + jdc + ' ' + lotsofsix[jdc]);
jdc=Math.floor(Math.random() * lotsofsix.length);
thisalert('This ' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ' sestet snippet is ... ' + lotsofsix[jdc].split(';')[eval((',' + cindxs + ',').split(',' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ':')[1].split(',')[0])].replace(/\<br\>/g, String.fromCharCode(10)));
}
} else if (othis.outerHTML.substring(1).split(' ')[0].split('>')[0] == 'details' || (othis.outerHTML.substring(1).split(' ')[0].split('>')[0] == 'body' && blurbsuffix == '') || noway) {
//alert(1967);
noway=true;
if (othis.outerHTML.substring(1).split(' ')[0].split('>')[0] == 'body') { noway=false; }
} else {
//alert(blurbsuffix + ' ... ' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0]);
if (('' + othis.id) != '') { extras=' ID=' + othis.id; idfound=true; } else {
if (eval('' + jdc) >= eval('' + lotsofsix.length)) { jdc=0; }
if (eval('' + detnum) > 0) {
if (lotsofsix[jdc].split(';')[idc].indexOf('<br>') != -1) {
if (document.getElementById('det' + eval(-1 + detnum))) {
document.getElementById('det' + eval(-1 + detnum)).open=false;
}
}
}
blurb+='<br>' + lotsofsix[jdc].split(';')[idc].replace('<br>', '<br><details onclick="noway=false;" id=det' + detnum + ' open><summary>') + detsuffix; detsuffix='';
}
detsuffix='';
if (othis.outerHTML.substring(1).split(' ')[0].split('>')[0] == 'body' && !idfound) {
var suf=tableize(blurb.replace('</summary><br>', '</summary>') + blurbsuffix);
if (suf != '') { document.getElementById('results').innerHTML+=suf; }
//alert(document.getElementById('results').innerHTML);
detsuffix='';
blurbsuffix='';
detnum++;
} else if (idfound) {
detsuffix='';
blurbsuffix='';
document.getElementById('results').innerHTML+=othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + extras + ' clicked.<br>';
} else if (('' + event.target.outerHTML).substring(1).split(' ')[0].split('>')[0] != 'button') {
//alert(967);
if ((',' + cindxs + ',').indexOf(',' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ':') != -1) {
jdc=Math.floor(Math.random() * lotsofsix.length);
thisalert('This ' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ' sestet snippet is ... ' + lotsofsix[jdc].split(';')[eval((',' + cindxs + ',').split(',' + othis.outerHTML.substring(1).split(' ')[0].split('>')[0] + ':')[1].split(',')[0])].replace(/\<br\>/g, String.fromCharCode(10)));
}
}
jdc++;
}
}
break;
default:
console.log('huh ' + event.type);
break;
}
}
function nooptetih() {
document.getElementById('optet').innerHTML='';
}
function getnewq() {
var thisopt='+';
pans=11;
if (eval('' + operopts.length) < 1) { operopts=document.getElementById('oper').innerHTML.split('</option>'); }
var myop=Math.floor(Math.random() * eval(-1 + operopts.length));
document.getElementById('oper').value='' + operopts[myop].split('">')[1];
document.getElementById('firstnum').value='' + Math.floor(Math.random() * 9);
document.getElementById('secnum').value='' + Math.floor(Math.random() * 9);
if (document.getElementById('oper').value == '**') {
pans=eval('' + Math.pow(eval('' + document.getElementById('firstnum').value), eval('' + document.getElementById('secnum').value)));
} else {
pans=eval('' + eval('' + document.getElementById('firstnum').value) + ' ' + document.getElementById('oper').value + ' ' + eval('' + document.getElementById('secnum').value));
}
while (('' + pans).replace('NaN','.').indexOf('.') != -1 || eval(('' + pans)) >= 10 || eval(('' + pans)) < 1) {
myop=Math.floor(Math.random() * eval(-1 + operopts.length));
document.getElementById('oper').value='' + operopts[myop].split('">')[1];
document.getElementById('firstnum').value='' + Math.floor(Math.random() * 9);
document.getElementById('secnum').value='' + Math.floor(Math.random() * 9);
if (document.getElementById('oper').value == '**') {
pans=eval('' + Math.pow(eval('' + document.getElementById('firstnum').value), eval('' + document.getElementById('secnum').value)));
} else {
pans=eval('' + eval('' + document.getElementById('firstnum').value) + ' ' + document.getElementById('oper').value + ' ' + eval('' + document.getElementById('secnum').value));
}
}
//document.getElementById('ians').value='' + pans;
document.getElementById('ians').value='';
setTimeout(function(){ document.getElementById('ians').focus(); }, 2000);
}
function checkans(oin) {
var origjscore=jscore;
jgoes++;
document.getElementById('goes').innerHTML='' + jgoes;
if (('' + oin.value) == ('' + pans)) { jscore+=ifactor; } else { document.getElementById('goes').innerHTML='' + jgoes + ' ... last answer was ' + pans; }
document.getElementById('score').innerHTML='' + jscore;
ifactor=1;
if (origjscore != jscore) {
if (document.getElementById('mr_ed').src.indexOf('karaoke') != -1 && document.getElementById('mr_ed').src.indexOf('&rand=') != -1) {
document.getElementById('mr_ed').src=document.getElementById('mr_ed').src.split('&rand=')[0] + '&rand=' + Math.floor(Math.random() * 19878675);
} else {
var ds=document.getElementById('mr_ed').getAttribute('data-src');
if (ds.indexOf('rjmprogramming.com.au') != -1) {
document.getElementById('mr_ed').src=ds.split('rjmprogramming.com.au')[1];
} else {
document.getElementById('mr_ed').src=ds;
}
document.getElementById('mr_ed').style.display='block';
}
}
getnewq();
}
</script>
</head>
<body onload=" if (window.self == window.parent) { document.getElementById('ians').focus(); } if (!navigator.userAgent.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile/i)) { document.getElementById('eventtype').size=document.getElementById('eventtype').getAttribute('data-size'); document.getElementById('actionsel').size=document.getElementById('actionsel').getAttribute('data-size'); } setTimeout(nooptetih, 8000); " onclick="moi(this);" onwheel="moi(this);" onauxclick="moi(this);" oncontextmenu="moi(this);" ondblclick="moi(this);" onmouseover="moi(this);" onmouseout="moi(this);" onmousedown="moi(this);" ontouchdown="moi(this);" ontouchstart="moi(this);" ontouchend="moi(this);">
<h1 id=myh1>Mister Ed Mathematics <span id=numbers></span></h1>
<h3 id=myh3>RJM Programming - October, 2024 - Score <span id=score>0</span>/<span id=goes>0</span></h3>
<h4 id=memaths>What is <input style=display:inline-block;width:50px; type='text' id='firstnum' name='firstnum' value='1'></input> <select style=display:inline-block; id=oper name=oper>
<option value='+'>+</option>
<option value='-'>-</option>
<option value='*'>*</option>
<option value='/'>/</option>
<option value='**'>**</option>
<option value='%'>%</option>
</select><input style=display:inline-block;width:50px; type='text' id='secnum' name='secnum' value='1'></input><span> = </span><input id=ians onblur=checkans(this); style=display:inline-block;width:500px; type=text placeholder='Mobile users can gesture with correct number of fingers involved, for extra score.' value=''></input><span> ? </span></h4>
<div id=noshow style=display:none;>
<h4 style='vertical-align:middle;'>Showing Onclick Event <br>Propagation in <input title='Rather than Onclick' onclick="event.stopPropagation(); if (document.getElementById('eventtype').value == 'contextmenu' && document.getElementById('actionsel').value == '' && this.checked) { document.getElementById('actionsel').value='preventDefault'; } else if (document.getElementById('eventtype').value != 'contextmenu' && document.getElementById('actionsel').value == 'preventDefault') { document.getElementById('actionsel').value=''; }" type=checkbox id=mycbomo style=display:inline-block;vertical-align:middle;></input> <select onclick="event.stopPropagation();" onchange="if (this.value != '') { if (this.value == 'contextmenu' && document.getElementById('actionsel').value == '' && document.getElementById('mycbomo').checked) { document.getElementById('actionsel').value='preventDefault'; } else if (this.value != 'contextmenu' && document.getElementById('actionsel').value == 'preventDefault') { document.getElementById('actionsel').value=''; } }" style=display:inline-block;vertical-align:middle; id=eventtype data-size=11 title='Event Type'><option id=optet value=''>Event Type ...</option><option value=mouseover>Onmouseover</option><option value=mousedown>Onmousedown</option><option value=mouseout>Onmouseout</option><option value=touchstart>Ontouchstart</option><option value=touchdown>Ontouchdown</option><option value=touchend>Ontouchend</option><option value=dblclick>Ondblclick</option><option value=contextmenu>Oncontextmenu</option><option value=auxclick>Onauxclick</option><option value=wheel>Onwheel</option></select> <select onclick="event.stopPropagation();" style=display:inline-block;vertical-align:middle; id=actionsel data-size=8 title='Curbs to Event Action'><option value='' selected>Action</option><option value=preventDefault>Prevent Default Action</option><option value=stopPropagation>Stop Propagation Action</option><option value=preventDefaultstopPropagation>Prevent Default & Stop Propagation Action</option><option value='noonclick'>No Onclick Action</option><option value=preventDefaultnoonclick>Prevent Default No Onclick Action</option><option value=stopPropagationnoonclick>Stop Propagation No Onclick Action</option><option value=preventDefaultstopPropagationnoonclick>Prevent Default & Stop Propagation No Onclick Action</option></select> <span id=numberst></span></h4>
<h5 id=myh5>Thanks to <a target=_blank title='https://sites.google.com/site/examplesinpoetry/sestet-poetry-example-definition' href='https://sites.google.com/site/examplesinpoetry/sestet-poetry-example-definition'>Examples in Poetry</a> and <a target=_blank title='https://bilingualkidspot.com/2018/04/23/popular-nursery-rhymes-for-kids-english/' href='https://bilingualkidspot.com/2018/04/23/popular-nursery-rhymes-for-kids-english/'>Bilingual Kidspot</a> and Emily Dickinson and William Shakespeare</h5>
<table border=20 onclick="moi(this);" onauxclick="moi(this);" oncontextmenu="moi(this);" ondblclick="moi(this);" onmouseover="moi(this);" onmouseout="moi(this);" onmousedown="moi(this);" ontouchdown="moi(this);" ontouchstart="moi(this);" ontouchend="moi(this);">
<tbody onclick="moi(this);" onauxclick="moi(this);" oncontextmenu="moi(this);" ondblclick="moi(this);" onmouseover="moi(this);" onmouseout="moi(this);" onmousedown="moi(this);" ontouchdown="moi(this);" ontouchstart="moi(this);" ontouchend="moi(this);">
<tr onclick="moi(this);" onauxclick="moi(this);" oncontextmenu="moi(this);" ondblclick="moi(this);" onmouseover="moi(this);" onmouseout="moi(this);" onmousedown="moi(this);" ontouchdown="moi(this);" ontouchstart="moi(this);" ontouchend="moi(this);"><td onclick="moi(this);" onauxclick="moi(this);" oncontextmenu="moi(this);" ondblclick="moi(this);" onmouseover="moi(this);" onmouseout="moi(this);" onmousedown="moi(this);" ontouchdown="moi(this);" ontouchstart="moi(this);" ontouchend="moi(this);"><button onclick=" detsuffix='</summary>'; blurbsuffix='</details>'; idc=Math.floor(Math.random() * lotsofsix[0].split(';').length); jdc=0; blurb=''; idfound=false; moi(this);" title="Little Ditty">Sestet ...</button></td></tr>
</tbody>
</table>
<br><br>
<div id=results style='border: 5px dotted green;display:block;'>
</div>
</div>
<iframe id=mr_ed style=display:none;width:95%;height:800px; src=/About_Us.html data-src=//www.rjmprogramming.com.au/HTMLCSS/karaoke_youtube_api.htm?youtubeid=hMPbipfgQ2c&youtube_duration=41.808&email=&email=&emoji=on&c0=on&i0=9&j0=11&i1=&j1=&i2=&j2=&i3=&j3=&i4=&j4=&i5=&j5=&i6=&j6=&i7=&j7=&i8=&j8=&i9=&j9=&i10=&j10=&i11=&j11=&i12=&j12=&i13=&j13=&i14=&j14=&i15=&j15=&i16=&j16=&i17=&j17=&i18=&j18=&i19=&j19=&i20=&j20=&i21=&j21=&i22=&j22=&i23=&j23=&i24=&j24=&i25=&j25=&i26=&j26=&i27=&j27=&i28=&j28=&i29=&j29=&rand='></iframe>
<input id=jans style=position:absolute;top:-200px;left:-200px; type=text value=''></input>
</body>
</html>