Abundant odd numbers: Difference between revisions
m
Fixed the propagated typo of "abundant primes".
mNo edit summary |
m (Fixed the propagated typo of "abundant primes".) |
||
Line 421:
const int max = 25;
cout << "The first " << max << " abundant odd
int n = abundantOdd(1, 0, 25, false);
Line 433:
}</lang>
{{out}}
<pre>The first 25 abundant odd
1. 945 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 27 + 35 + 45 + 63 + 105 + 135 + 189 + 315 = 975
2. 1575 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 25 + 35 + 45 + 63 + 75 + 105 + 175 + 225 + 315 + 525 = 1649
Line 579:
void main() {
const int max = 25;
writefln("The first %d abundant odd
int n = abundantOdd(1, 0, 25, false);
Line 589:
}</lang>
{{out}}
<pre>The first 25 abundant odd
1. 945 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 27 + 35 + 45 + 63 + 105 + 135 + 189 + 315 = 975
2. 1575 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 25 + 35 + 45 + 63 + 75 + 105 + 175 + 225 + 315 + 525 = 1649
Line 1,059:
fun main() {
val max = 25
println("The first $max abundant
val n = abundantOdd(1, 0, 25, false)
Line 1,069:
}</lang>
{{out}}
<pre>The first 25 abundant
1. 945 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 27 + 35 + 45 + 63 + 105 + 135 + 189 + 315 = 975
2. 1575 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 25 + 35 + 45 + 63 + 75 + 105 + 175 + 225 + 315 + 525 = 1649
Line 1,784:
fn main() {
let max = 25;
println!("The first {} abundant odd
let n = abundant_odd(1, 0, max, false);
Line 1,794:
}</lang>
{{out}}
<pre>The first 25 abundant odd
1. 945 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 27 + 35 + 45 + 63 + 105 + 135 + 189 + 315 = 975
2. 1575 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 25 + 35 + 45 + 63 + 75 + 105 + 175 + 225 + 315 + 525 = 1649
Line 1,878:
def main(args: Array[String]): Unit = {
val max = 25
printf("The first %d abundant odd
val n = abundantOdd(1, 0, max, printOne = false)
Line 1,889:
}</lang>
{{out}}
<pre>The first 25 abundant odd
1. 945 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 27 + 35 + 45 + 63 + 105 + 135 + 189 + 315 = 975
2. 1575 < 1 + 3 + 5 + 7 + 9 + 15 + 21 + 25 + 35 + 45 + 63 + 75 + 105 + 175 + 225 + 315 + 525 = 1649
|