var count = 1;
function selectMatrix(num1,num2) {
    count++;
    var counter = 1;
    var counter1 = 1;
    var counter2 = 4;
    for (j = 0; j < 11; j++) {
        div = document.createElement("div");
        div.setAttribute("id", "outerDiv" + (j + 1));
        div.setAttribute("class", " nopadding col-sm-12 col-lg-12 col-md-12 col-xs-12");
        document.getElementById('questions').appendChild(div);
        if (j == 1)
            counter = 1;
        for (var i = 1; i < 11; i++) {//11
            Div = document.createElement("div");
            Div.setAttribute("id", "div" + (j) + (i));
            Div.setAttribute("class", " nopadding quetions text-center col-sm-1 col-lg-1 col-md-1 col-xs-1");//
            div.appendChild(Div);
            Div.style.height = "5.7vh";
            Div.style.width = "4.7vw";
           /* if (i == 0 && j == 0) {
                document.getElementById("div" + (j) + (i)).innerHTML = "X";
                document.getElementById("div" + (j) + (i)).style.backgroundColor = "rgb(139, 216, 84)";
            }
            if (i == 0 && j > 0) {
				if(counter1==num1 || counter1==num2)
					document.getElementById("div" + (j) + (i)).style.backgroundColor = "yellow";
				else
					document.getElementById("div" + (j) + (i)).style.backgroundColor = "white";
                document.getElementById("div" + (j) + (i)).innerHTML = counter1;
                document.getElementById("div" + (j) + (i)).setAttribute("data", "Left");
            }*/
            if (i == 1 && j > 0) {
                document.getElementById("div" + (j) + (i)).innerHTML = counter1;
                document.getElementById("div" + (j) + (i)).style.backgroundColor = "rgb(230, 227, 182)";
                counter1++;
            }
            if (j == 0 && i > 0) {
				document.getElementById("div" + (j) + (i)).style.backgroundColor = "white";
				document.getElementById("div" + (j) + (i)).innerHTML = counter;
                counter++;
            }
            if (j == 1 && i > 0) {
				if(counter==num1)
					document.getElementById("div" + (j) + (i)).style.backgroundColor = "yellow";
				else if (counter==num2)
					document.getElementById("div" + (j) + (i)).style.backgroundColor = "pink";
				else
					document.getElementById("div" + (j) + (i)).style.backgroundColor = "rgb(230, 227, 182)";
                document.getElementById("div" + (j) + (i)).innerHTML = counter;
                counter++;
            }
            if (j > 1 && i > 1) {
				if(counter2==num1)
					document.getElementById("div" + (j) + (i)).style.backgroundColor = "yellow";
				else if (counter2==num2)
					document.getElementById("div" + (j) + (i)).style.backgroundColor = "pink";
				else
					document.getElementById("div" + (j) + (i)).style.backgroundColor = "rgb(230, 227, 182)";
                document.getElementById("div" + (j) + (i)).innerHTML = counter2;
                counter2 = counter2 + j;
            }
        }
        counter2 = 2 * (j + 1);
        counter = 1 + j + 1;
    }
}