Age Calculator



Calculate

<form>
  <label for="dob">Date of Birth:</label><br>
  <input type="date" id="dob" name="dob"><br>
  <button onclick="calculateAge()">Calculate</button>
</form> 

<script>
  function calculateAge() {
    // Get the date of birth from the form
    var dob = document.getElementById("dob").value;
    
    // Convert the date of birth to a JavaScript Date object
    var dateOfBirth = new Date(dob);
    
    // Get the current date
    var today = new Date();
    
    // Calculate the age in years
    var age = Math.floor((today - dateOfBirth) / (365.25 * 24 * 60 * 60 * 1000));
    
    // Display the age
    alert("Your age is: " + age);
  }
</script>

Another coding:



SIP Calculator:











Total investment:








Total investment:

Total interest: