onchange need to reset the value in jquery : on load I got my input value 5.02, now i need to change in 6.
 now i am getting either null or 5.02. 

how i can get my data is 6???

My code is:::

    	 <input type="number" id="rate" class="form-control rate " th:value="${abc.rate}" placeholder="Rate" /> 

javaScript:::

    		$(".rate input[type='number']").change(function() {
   			 $("#rate").val("");//i am reseting the value
  			 rateForA =$('#rate').val();//but i am getting null
     			 console.log(rateForA );

		});

