Anonymous user
Magic squares of doubly even order: Difference between revisions
Magic squares of doubly even order (view source)
Revision as of 22:45, 3 September 2019
, 4 years ago→{{header|Rust}}: Optimization of width
m (→{{header|Rust}}: Optimization of width) |
|||
Line 2,174:
let mc = (n * n + 1) * n / 2;
println!("Magic constant: {}\n", mc);
let width =
let bits = 0b1001_0110_0110_1001u32;
let size = n * n;
Line 2,200:
Magic constant: 260
</pre>
=={{header|Scala}}==
{{Out}}Best seen running in your browser either by [https://scalafiddle.io/sf/bdTcGF3/0 ScalaFiddle (ES aka JavaScript, non JVM)] or [https://scastie.scala-lang.org/gLhkwHHlRO6rPXg9U7MDzg Scastie (remote JVM)].
|