zoukankan      html  css  js  c++  java
  • 记一次无聊的视力测试

    http://www.lezyo.com/special/game/color/?from=singlemessage&isappinstalled=

    Chrome:

    F12-Console输入

    setInterval(function () {
    var first = '';
    var firstCount = 0;
    var firstIndex = 0;
    
    var second = '';
    var secondCount = 0;
    var secondIndex = 0;
    $("#box").children("span").each(function (i) {
    if (i == 0) {
    first = $(this).css("background-color");
    firstIndex = i;
    firstCount++;
    return;
    }
    
    if (first == $(this).css("background-color")) {
    firstIndex = i;
    firstCount++;
    } else {
    second == $(this).css("background-color");
    secondIndex = i;
    second++;
    }
    });
    if (firstCount == 1) {
    $("#box").children("span").eq(firstIndex).click();
    } else {
    $("#box").children("span").eq(secondIndex).click();
    }
    }, 1);
  • 相关阅读:
    Codeforces Round #534 (Div. 2) D. Game with modulo 交互题
    传球游戏 dp
    欧拉通路和欧拉回路
    HDU 1116
    HDU 4970
    HDU 4557
    HDU 4864
    HDU 1565
    HDU 3046
    HDU 4240
  • 原文地址:https://www.cnblogs.com/shenqiboy/p/4673852.html
Copyright © 2011-2022 走看看