function showScore(nBulls, nCows) {
    var guessCount = "";
    if (maxGuesses) {
        guessCount = ("/" + maxGuesses);
    }
    if (nGuesses < 5) {
        $("#score").children("a:first").remove();
    }
    $("#score").append(
            "\<a href=\"#\" class=\"list-group-item disabled\"\>" +
            nGuesses + guessCount + ": " +
            guess.join("") +
            "\<span class=\"bull\"\>&#x1F402;: " + nBulls +"\<\/span\>" +
            "\<span class=\"cow\"\>&#x1F404;: " + nCows + "\<\/span\>" +
            "\<\/a\>");
    $("#score").animate({ scrollTop: $("#score")[0].scrollHeight }, "slow");
}
/* Updates the entry list with the current guess.
 * Also deletes the initial empty lists.
 * Scrolls to the bottom, where new entry is created.
 * ------------------------------------------------------------------------- */
Updates the entry list with the current guess.
Also deletes the initial empty lists.
Scrolls to the bottom, where new entry is created.
Updates the entry list with the current guess . Also deletes the initial empty lists . Scrolls to the bottom where new entry is created .
function showScore(nBulls, nCows) {
    var guessCount = "";
    if (maxGuesses) {
        guessCount = ("/" + maxGuesses);
    }
    if (nGuesses < 5) {
        $("#score").children("a:first").remove();
    }
    $("#score").append(
            "\<a href=\"#\" class=\"list-group-item disabled\"\>" +
            nGuesses + guessCount + ": " +
            guess.join("") +
            "\<span class=\"bull\"\>&#x1F402;: " + nBulls +"\<\/span\>" +
            "\<span class=\"cow\"\>&#x1F404;: " + nCows + "\<\/span\>" +
            "\<\/a\>");
    $("#score").animate({ scrollTop: $("#score")[0].scrollHeight }, "slow");
}
function showScore ( nBulls , nCows ) { var guessCount = "" ; if ( maxGuesses ) { guessCount = ( "/" + maxGuesses ) ; } if ( nGuesses < 5 ) { $ ( "#score" ) . children ( "a:first" ) . remove ( ) ; } $ ( "#score" ) . append ( "\<a href=\"#\" class=\"list-group-item disabled\"\>" + nGuesses + guessCount + ": " + guess . join ( "" ) + "\<span class=\"bull\"\>&#x1F402;: " + nBulls + "\<\/span\>" + "\<span class=\"cow\"\>&#x1F404;: " + nCows + "\<\/span\>" + "\<\/a\>" ) ; $ ( "#score" ) . animate ( { scrollTop : $ ( "#score" ) [ 0 ] . scrollHeight } , "slow" ) ; }
Updates the entry list with the current guess.
Updates the entry list with the current guess .