This has got to be something simple. I searched the internet and only found syntax errors as the cause of this problem, but I can\'t find a syntax error.
The hi function is only in scope inside the ready event handler. Move it outside of the event handler, or handle the binding inside there (and remove the inline event handler attribute from the markup):
$(document).ready(function(){
function hi(){
alert('hi');
}
$("#cep").on("change", hi);
});