diff options
| author | nsfisis <nsfisis@gmail.com> | 2024-09-07 11:31:07 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2024-09-07 11:31:07 +0900 |
| commit | 4db9b0d4d646dc903c2c4a94b27112866484c623 (patch) | |
| tree | 4c155b1f376fbc4f1c2ab20ec6b419018569bd8a /problems/14-Matrix-Square/testcase_1_double_4x4.rb | |
| parent | e151eb305498b48668b04d81cbfe799511a2fda5 (diff) | |
| download | mncore-challenge-4db9b0d4d646dc903c2c4a94b27112866484c623.tar.gz mncore-challenge-4db9b0d4d646dc903c2c4a94b27112866484c623.tar.zst mncore-challenge-4db9b0d4d646dc903c2c4a94b27112866484c623.zip | |
14-Matrix-Square: testcase 1 - double 4x4
Diffstat (limited to 'problems/14-Matrix-Square/testcase_1_double_4x4.rb')
| -rw-r--r-- | problems/14-Matrix-Square/testcase_1_double_4x4.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/problems/14-Matrix-Square/testcase_1_double_4x4.rb b/problems/14-Matrix-Square/testcase_1_double_4x4.rb new file mode 100644 index 0000000..106e48a --- /dev/null +++ b/problems/14-Matrix-Square/testcase_1_double_4x4.rb @@ -0,0 +1,10 @@ +require 'matrix' + +a = Matrix[ + [3.0, 9.0, 7.0, 5.0], + [1.0, 1.0, 0.0, 8.0], + [6.0, 7.0, 0.0, 9.0], + [8.0, 2.0, 1.0, 1.0], +] + +puts a**2 |
