Created
December 3, 2020 20:43
-
-
Save grze2000/209a3ee1729726f5a63c10452f8fe2ba to your computer and use it in GitHub Desktop.
Funkcje matematyczne w JS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>JS</title> | |
</head> | |
<body> | |
<script> | |
document.write('3<br>'); | |
document.write('π^e = ' + Math.pow(Math.PI, Math.E), '<br>'); | |
document.write('e^π = ' + Math.exp(Math.PI), '<br>'); | |
const x = 1.345; | |
document.write('4<br>'); | |
document.write('a) ', (3 * Math.exp(-x) + Math.cbrt(x + 3)) / (Math.log10(x + 5) - 1), '<br>'); | |
document.write('b) ', (Math.pow(Math.log(x) + 4, 1/4) - 1) / (Math.pow(Math.sin(Math.pow(x, 2) - 1), 2) - 1), '<br>'); | |
document.write('c) ', (Math.pow(Math.cos((Math.PI * x) / 2), 2) + Math.sin(Math.PI) * x) / (Math.abs(Math.exp(-3 * x) - 1) - 1 / x), '<br>'); | |
document.write('5<br>'); | |
document.write(Math.floor(Math.random() * 100) + 100); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment