JavaScript Basic Temperature Converter
Ruls:
Fahrenheit to Celsius is: C = (°F - 32) × 5/9
Celsius to Fahrenheit is: F = (°C *(9/5)+ 32
<!DOCTYPE html>
<html>
<head>
<title>JavaScript Basic Temperature Converter</title>
</head>
<body>
<p>JavaScript Basic Temperature Converter</p>
<script type="text/javascript">
var num =parseFloat(prompt("Enter a number "));
var celsius=(num-32)*(5/9);
var farnharet=(num*(9/5))+32;
document.write("Fahrenheit to Celsius is: "+celsius+"?C"+"<br/>");
document.write("Celsius to Fahrenheit is: "+farnharet+"?F");
</script>
</body>
</html>