Question: If I were to encrypt a string of arbitrary length (let's say using md5), is there any relation between increasing string size to the output hash? 

For example, if I were to encrypt a string that was 100 million characters in length, would it be more likely to output a longer hash than an input string of 5 characters?

Elaboration on why would be much appreciated as well, thanks!

Answer: 
Fixed the issue

```
if (digits %2 == 0) 
{
      var mystring = $( "#numBox" ).html();
      mystring = mystring.replace('.','');
      $( "#numBox" ).html(mystring);
      $( "#numBox" ).append(".");
      console.log("worked!");
}

```

Check the updated code on <http://codepen.io/bsley/pen/hrEmK>

Try this

```
$(document).ready(function(){

  var digits = 0; 
  var numBox = document.getElementById('numBox');

    $('.key').click(function(){

        if(this.innerHTML == '0'){
            if (numBox.innerHTML.length > 0)
                numBox.innerHTML = numBox.innerHTML + this.innerHTML;
                digits += 1;
                //console.log("digits");

        }
        else
            // add digits          
            numBox.innerHTML = numBox.innerHTML + this.innerHTML;
            digits += 1;
            //console.log(digits);

        event.stopPropagation();
    });

    $('.btn').click(function(){
        if(this.innerHTML == 'DEL'){
            var numBox = document.getElementById('numBox');
            if(numBox.innerHTML.length > 0){

                // delete a digit
                numBox.innerHTML = numBox.innerHTML.substring(0, numBox.innerHTML.length - 1);
                digits -= 1;
                //console.log(digits);
            }
        }
        else{

            // clear numbox
            document.getElementById('numBox').innerHTML = '';
            digits = 0;
            //console.log(digits);
        }

        event.stopPropagation();
        _checkForDecimals();
    });

    //decimal entry

    $('.key').click(function(){

    _checkForDecimals();

 });

  function _checkForDecimals()
  {
   if (digits > 2) {
      var mystring = $( "#numBox" ).html();
      mystring = mystring.replace('.','');
      var firstPartOfString = mystring.slice(0, mystring.length - 2);
      var secondPartOfString =  mystring.slice( mystring.length - 2,mystring.length);
      //alert(firstPartOfString+'.'+secondPartOfString)
      mystring = firstPartOfString+'.'+secondPartOfString;
      $( "#numBox" ).html(mystring);
      //$( "#numBox" ).append(".");
      console.log("worked!");
    } 
  }

});

```
try something like this

```
        var str = "12.345";
        str= str.replace("\.","");
        if(str.length > 2){
            str = str.substr(0, str.length - 2) + '.' + str.substr(str.length - 2);
        }
        alert(str);

```