|
Scala example source code file (Course-2002-02-msil.check)
The Scala Course-2002-02-msil.check source code7 120 10 100 2.08333333333333 3025.76877140318 pi = 3.16597927284322 10 100 2.08333333333333 3025.76877140318 pi = 3.16597927284322 10 100 2.08333333333333 3025.76877140318 pi = 3.16597927284322 10 100 2.08333333333333 3025.76877140318 pi = 3.16597927284322 10 100 2.08333333333333 3025.76877140318 pi = 3.16597927284322 10 100 2.08333333333333 3025.76877140318 pi = 3.16597927284322 10 100 2.08333333333333 3025.76877140318 pi = 3.16597927284322 pi = 3.18110488557771 pi = 3.18110488557771 10 100 2.08333333333333 3025.76877140318 pi = 3.16597927284322 pi = 3.18110488557771 pi = 3.18110488557771 1.5 1.41666666666667 1.41421568627451 1.41421356237469 sqrt(2) = 1.41421356237469 1.5 1.41666666666667 1.41421568627451 1.41421356237469 sqrt(2) = 1.41421356237469 1 + 2 + .. + 5 = 15 1 * 2 * .. * 5 = 120 1^2 + 2^2 + .. + 5^2 = 55 1^2 * 2^2 * .. * 5^2 = 14400 factorial(0) = 1 factorial(1) = 1 factorial(2) = 2 factorial(3) = 6 factorial(4) = 24 factorial(5) = 120 1 + 2 + .. + 5 = 15 1 * 2 * .. * 5 = 120 1^2 + 2^2 + .. + 5^2 = 55 1^2 * 2^2 * .. * 5^2 = 14400 factorial(0) = 1 factorial(1) = 1 factorial(2) = 2 factorial(3) = 6 factorial(4) = 24 factorial(5) = 120 1 + 2 + .. + 5 = 15 1 * 2 * .. * 5 = 120 1^2 + 2^2 + .. + 5^2 = 55 1^2 * 2^2 * .. * 5^2 = 14400 factorial(0) = 1 factorial(1) = 1 factorial(2) = 2 factorial(3) = 6 factorial(4) = 24 factorial(5) = 120 fib(0) = 0 fib(1) = 1 fib(2) = 1 fib(3) = 2 fib(4) = 3 fib(5) = 5 fib(6) = 8 fib(7) = 13 fib(8) = 21 fib(9) = 34 fib(0) = 0 fib(1) = 1 fib(2) = 1 fib(3) = 2 fib(4) = 3 fib(5) = 5 fib(6) = 8 fib(7) = 13 fib(8) = 21 fib(9) = 34 power(0,0) = 1 power(0,1) = 0 power(0,2) = 0 power(0,3) = 0 power(0,4) = 0 power(0,5) = 0 power(0,6) = 0 power(0,7) = 0 power(0,8) = 0 power(1,0) = 1 power(1,1) = 1 power(1,2) = 1 power(1,3) = 1 power(1,4) = 1 power(1,5) = 1 power(1,6) = 1 power(1,7) = 1 power(1,8) = 1 power(2,0) = 1 power(2,1) = 2 power(2,2) = 4 power(2,3) = 8 power(2,4) = 16 power(2,5) = 32 power(2,6) = 64 power(2,7) = 128 power(2,8) = 256 power(3,0) = 1 power(3,1) = 3 power(3,2) = 9 power(3,3) = 27 power(3,4) = 81 power(3,5) = 243 power(3,6) = 729 power(3,7) = 2187 power(3,8) = 6561 power(4,0) = 1 power(4,1) = 4 power(4,2) = 16 power(4,3) = 64 power(4,4) = 256 power(4,5) = 1024 power(4,6) = 4096 power(4,7) = 16384 power(4,8) = 65536 power(5,0) = 1 power(5,1) = 5 power(5,2) = 25 power(5,3) = 125 power(5,4) = 625 power(5,5) = 3125 power(5,6) = 15625 power(5,7) = 78125 power(5,8) = 390625 Other Scala examples (source code examples)Here is a short list of links related to this Scala Course-2002-02-msil.check source code file: |
... this post is sponsored by my books ... | |
#1 New Release! |
FP Best Seller |
Copyright 1998-2024 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.