microsoft/qdk

Public

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

CodeCommitsIssuesPull requestsActionsInsightsSecurity
v1.3.0

Branches

Tags

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

Clone

HTTPS

Download ZIP

katas/content/complex_arithmetic/complex_modulus/solution.md

3lines · modepreview

The modulus of the complex number can be seen as the distance from the origin 0 to the point $x$ in the complex plane. This can be calculated using the Pythagorean theorem: $c^2 = a^2 + b^2$, which means $ c = \sqrt{a^2 + b^2}$

@[solution]({"id": "complex_arithmetic__complex_modulus_solution", "codePath": "Solution.qs"})