NEP CMA

PART -A

PROGRAM 1 PROGRAM 2 PROGRAM 3 PROGRAM 4 PROGRAM 5 PROGRAM 6 PROGRAM 7 PROGRAM 8

PART-B

PROGRAM B1 PROGRAM B2 PROGRAM B3 PROGRAM B4 PROGRAM B5 PROGRAM B6 PROGRAM B7 PROGRAM B8 . . .

 
  
 
 
  
      
      <!DOCTYPE html>
<html>
<title>Fahrenheit to Celcius Temperature Converter</title>
<body>

<h2>Temperature Converter</h2>
<p>Write a JavaScript program to convert temperatures to and from Celsius, Fahrenheit <br>
Type a value in the Fahrenheit field to convert the value to Celsius:</p>

<p>
  <label>Celcius:</label>
  <input id="inputCelsius" type="number" placeholder="Fahrenheit" oninput="temperatureConverter(this.value)" onchange="temperatureConverter(this.value)">
</p>
<p> Fahrenheit:<span id="outputFahrenheit"></span></p>

<script>
function temperatureConverter(valNum) {
  valNum = parseFloat(valNum);
  document.getElementById("outputFahrenheit").innerHTML=(valNum*1.8)+32;
 
}
</script>

</body>
</html>