Data update
This commit is contained in:
parent
0df55f9f24
commit
aec8ed51b6
1045 changed files with 18889 additions and 2777 deletions
14
Task/Tau-function/Asymptote/tau-function.asymptote
Normal file
14
Task/Tau-function/Asymptote/tau-function.asymptote
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
write("The tau functions for the first 100 positive integers are:");
|
||||
for (int N = 1; N <= 100; ++N) {
|
||||
int T;
|
||||
if (N < 3) {
|
||||
T = N;
|
||||
} else {
|
||||
T = 2;
|
||||
for (int A = 2; A <= (N + 1) / 2; ++A) {
|
||||
if (N % A == 0) T = T + 1;
|
||||
}
|
||||
}
|
||||
write(format("%3d", T), suffix=none);
|
||||
if (N % 10 == 0) write("");
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue