aasdfasdfasdfasdfasdf

This commit is contained in:
2023-03-22 13:47:37 -05:00
parent 01974fa83c
commit 0782b2c775
74 changed files with 1734 additions and 0 deletions

View File

@@ -0,0 +1,36 @@
<!DOCTYPE html>
<!--
Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
Click nbfs://nbhost/SystemFileSystem/Templates/ClientSide/html.html to edit this template
-->
<html>
<head>
<title>Bacteria cultivation calculator</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style>
table, th, td {
border: 1px solid;
text-align: center;
}
</style>
<script>
var initialBacteria = prompt("Enter the initial bacteria.");
var bacteria = initialBacteria;
document.write("<table>");
// Write table header
document.write("<tr><th>Initial Bacteria Present:</th><th>"+initialBacteria +"</th></tr>");
document.write("<tr><th>Bacteria</th><th>Day</th></tr>");
for (var i = 1; i <= 10; i++) {
document.write("<tr>");
bacteria = initialBacteria * Math.pow(2, (i / 10)) ;
bacteria = Math.trunc(bacteria);
document.write("<td>" + bacteria + "</td>");
document.write("<td>" + i + "</td>");
document.write("</tr>");
}
document.write("</table>");
</script>
</head>
</html>