Skip to content

Instantly share code, notes, and snippets.

@dnetguru
Last active June 16, 2016 13:09

Revisions

  1. Farzad E. revised this gist Dec 29, 2014. 1 changed file with 4 additions and 5 deletions.
    9 changes: 4 additions & 5 deletions gistfile1.html
    Original file line number Diff line number Diff line change
    @@ -15,13 +15,12 @@

    var mul = 0;
    function render(){
    for (i = (45 + ((mul * 308) - 10)); i < (45 + (mul * 308) + 10); i++)
    {
    if (i % 2 && gcd_rec(i, 210)==1) {
    for (i = 100154 + (308 * mul) + ((mul) * 49); i < 100154 + (308 * mul) + ((mul + 1) * 49); i++)
    {
    if (gcd_rec(i, 210)==1) {
    document.write(
    '\t <img title="'+ i +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + i + '">\t' +
    '<br>'
    );
    '<br>');
    }
    }
    document.write("<input type='button' value='Next Set' onclick='wow()'><br/>")
  2. Farzad E. revised this gist Dec 29, 2014. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion gistfile1.html
    Original file line number Diff line number Diff line change
    @@ -17,7 +17,7 @@
    function render(){
    for (i = (45 + ((mul * 308) - 10)); i < (45 + (mul * 308) + 10); i++)
    {
    if (i % 2 || gcd_rec(i, 210)==1) {
    if (i % 2 && gcd_rec(i, 210)==1) {
    document.write(
    '\t <img title="'+ i +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + i + '">\t' +
    '<br>'
  3. Farzad E. revised this gist Dec 29, 2014. 1 changed file with 18 additions and 7 deletions.
    25 changes: 18 additions & 7 deletions gistfile1.html
    Original file line number Diff line number Diff line change
    @@ -4,24 +4,35 @@
    <meta charset="utf-8">
    <title>JS Bin</title>
    <script>
    var mul = 1;

    function gcd_rec(a, b) {
    if (b) {
    return gcd_rec(b, a % b);
    } else {
    return Math.abs(a);
    }
    }

    var mul = 0;
    function render(){
    for (i = (44 * (mul - 1)) + 1; i < (44 * mul); i += 4)
    for (i = (45 + ((mul * 308) - 10)); i < (45 + (mul * 308) + 10); i++)
    {
    if (i % 2 || gcd_rec(i, 210)==1) {
    document.write(
    '\t <img title="'+ i +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + i + '">\t' +
    '\t <img title="'+ (i+1) +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + (i+1) + '">\t' +
    '\t <img title="'+ (i+2) +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + (i+2) + '">\t' +
    '\t <img title="'+ (i+3) +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + (i+3) + '">\t' +
    //'f(' + i + ')
    '<br>'
    );
    }
    }
    document.write("<input type='button' value='Next Set' onclick='wow()'><br/>")
    }
    render();
    function wow()
    {mul++;render();}
    {
    mul++;
    document.body.innerHTML = '';
    render();
    }
    </script>
    </head>
    <body>
  4. Farzad E. created this gist Dec 29, 2014.
    30 changes: 30 additions & 0 deletions gistfile1.html
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,30 @@
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="utf-8">
    <title>JS Bin</title>
    <script>
    var mul = 1;
    function render(){
    for (i = (44 * (mul - 1)) + 1; i < (44 * mul); i += 4)
    {
    document.write(
    '\t <img title="'+ i +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + i + '">\t' +
    '\t <img title="'+ (i+1) +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + (i+1) + '">\t' +
    '\t <img title="'+ (i+2) +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + (i+2) + '">\t' +
    '\t <img title="'+ (i+3) +'" src="https://hax.tor.hu/level30/?gen=1&pw=' + (i+3) + '">\t' +
    //'f(' + i + ')
    '<br>'
    );
    }
    document.write("<input type='button' value='Next Set' onclick='wow()'><br/>")
    }
    render();
    function wow()
    {mul++;render();}
    </script>
    </head>
    <body>

    </body>
    </html>