{"type":"rich","blog_title":"\u3089\u3093\u3060\u3080\u306a\u8a18\u61b6","blog_url":"https://randommemory.hatenablog.com/","url":"https://randommemory.hatenablog.com/entry/2022/04/30/213332","provider_name":"Hatena Blog","version":"1.0","height":"190","title":" <QT> \u91cf\u5b50\u534a\u52a0\u7b97\u5668","author_url":"https://blog.hatena.ne.jp/derwind/","provider_url":"https://hatena.blog","width":"100%","categories":["quantum_computing"],"published":"2022-04-30 21:33:32","image_url":"https://cdn-ak.f.st-hatena.com/images/fotolife/d/derwind/20220430/20220430220653.png","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Frandommemory.hatenablog.com%2Fentry%2F2022%2F04%2F30%2F213332\" title=\" &lt;QT&gt; \u91cf\u5b50\u534a\u52a0\u7b97\u5668 - \u3089\u3093\u3060\u3080\u306a\u8a18\u61b6\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","description":"The Atoms of Computation \u306e\u901a\u308a\u3060\u3051\u3069\u3002 def add(a, b): qc = QuantumCircuit(4, 2) if a != 0: qc.initialize([0, 1], 0) if b != 0: qc.initialize([0, 1], 1) qc.cx(0, 2) qc.cx(1, 2) qc.ccx(0, 1, 3) qc.measure(2, 0) qc.measure(3, 1) results = sim.run(qc).result() return [int(c) for c in sorted(results.get_counts\u2026","author_name":"derwind"}