Full version: jsB@nk » Game » Puzzle » Magic Square
URL: https://www.javascriptbank.com/magic-square.html
Put the numbers in order so that they read 1-8. The 0 is the 'empty' place. Click on any number next to 0 and they will switch places.
Full version: jsB@nk » Game » Puzzle » Magic Square
URL: https://www.javascriptbank.com/magic-square.html
<STYLE type=text/css>.num {FONT-SIZE: 12px; WIDTH: 30px; COLOR: #000; FONT-FAMILY: verdana; TEXT-ALIGN: right}.symbols {FONT-SIZE: 30px; BACKGROUND: #000; COLOR: #f1f1f1; FONT-FAMILY: wingdings; TEXT-ALIGN: center}.viewsymbol {FONT-SIZE: 100px; BACKGROUND: #000; WIDTH: 150px; COLOR: #f1f1f1; FONT-FAMILY: wingdings; HEIGHT: 150px}</STYLE><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->
<SCRIPT language=javascript>ax=0;function viewtable() { ax=Math.round(Math.random()*26); alphaArray=new Array("a", "n", "b", "d", "f", "h", "{", "i", "l", "v", "x", "z", "I", "J", "M", "N", "o", "O", "R", "S", "T", "U", "m", "6", "^", "u", "_", "[", "]"); table="<table align=\"center\" border=\"0\" cellspacing=\"5\" cellpadding=\"1\"><tr>"; j=1; for ( i = 99 ; i >= 0 ; i-- ) { a=Math.round(Math.random()*26); if(i%9 == 0 && i < 89) a=ax; table+="<td class=\"num\">"+i+"</td><td class=\"symbols\">"+alphaArray[a]+"</td>"; if(j%10 == 0) table+="</tr><tr>"; j++; } table+="</table>"; sym.innerHTML=table sh.innerHTML=""}function show() { sh.innerHTML=alphaArray[ax] sym.innerHTML="<center>Guess? :) <a href=\"javascript:viewtable()\">Repeat</a></center>";}</SCRIPT><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->
<BODY onload=viewtable();><TABLE cellSpacing=0 width="100%" border=0> <TBODY> <TR> <TD vAlign=top> <DD>"Magic Square" will guess a symbol you choose. Any magic, just javascript. But very interesting! <DD>1. Conceive any two-digit number<BR> <DD>2. Deduct from this number it's digits (e.g., from number 54 it's needed to deduct digits 5 and 4. Result is 45<BR> <DD>3. Find this number and corresponding symbol in the table below<BR> <DD>4. Imagine this symbol in your mind<BR> <DD>5. Click on the square<BR> <P></P> <TABLE style="CURSOR: hand" onclick=show() cellSpacing=10 align=center border=0> <TBODY> <TR> <TD class=viewsymbol id=sh align=middle> </TD></TR></TBODY></TABLE></DD></TD></TR> <TR> <TD id=sym vAlign=top></TD></TR></TBODY></TABLE></TD> <TD></TD></TR></TBODY></TABLE></BODY><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->