jsでこの関数を使用できないのはなぜですか:エラー:ReferenceError:new_tweetが定義されていません
function new_tweet(){
alert("here i am");
}
function add_div(){
mydiv = document.getElementById("new_twt");
mydiv.innerHTML="<input type='button' value='You have new conversations' onclick=new_tweet();>";
}