microsoft/qdk

Public

mirrored fromhttps://github.com/microsoft/qdkAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
amcasey/ArrayWrap

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

katas/content/linear_algebra/tensor_product/Verification.qs

17lines · modecode

1namespace Kata.Verification {
2 import Std.Math.*;
3
4 function TensorProduct_Reference() : Double[][] {
5 return [
6 [5., 6., 10., 12.],
7 [7., 8., 14., 16.],
8 [15., 18., 20., 24.],
9 [21., 24., 28., 32.]
10 ];
11 }
12
13 @EntryPoint()
14 operation CheckSolution() : Bool {
15 ArraysEqualD(Kata.TensorProduct(), TensorProduct_Reference())
16 }
17}
18