If you are not sure if the website you would like to visit is secure, you can verify it here. Enter the website address of the page and see parts of its content and the thumbnail images on this site. None (if any) dangerous scripts on the referenced page will be executed. Additionally, if the selected site contains subpages, you can verify it (review) in batches containing 5 pages.
favicon.ico: quantumcomputingcourses.com/tutorials/cirq-hello-world - Hello World in Cirq.

site address: quantumcomputingcourses.com/tutorials/cirq-hello-world redirected to: quantumcomputingcourses.com/tutorials/cirq-hello-world

site title: Hello World in Cirq

Our opinion (on Monday 28 September 2026 1:46:34 UTC):

GREEN status (no comments) - no comments
After content analysis of this website we propose the following hashtags:



Meta tags:
description=Write your first quantum program in Cirq, create a Bell state using GridQubits and Moments, run it on the Cirq simulator.;
author=;

Headings (most frequently used words):

cirq, quantum, example, state, what, to, learn, expected, output, hello, world, in, setting, up, bell, ghz, three, qubits, key, concepts, running, on, google, hardware, next, try, it, yourself, circuit, builder, related, tutorials, get, one, email, week, each, line, does, ready, go, deeper, reference, careers, about,

Text of the page (most frequently used words):
cirq (74), the (66), and (45), quantum (42), #circuit (27), state (24), qubits (23), with (21), #google (21), you (21), hardware (20), this (19), qubit (17), result (17), key (14), measurement (14), gates (13), simulator (13), two (13), courses (12), for (12), read (12), bell (12), that (12), all (11), cnot (11), processor (11), linequbit (11), guide (10), tutorials (10), circuits (10), are (10), print (10), each (10), ghz (9), run (9), from (8), computing (8), min (8), 1000 (8), binary (8), rangle (8), use (7), your (7), example (7), three (7), tutorial (7), gridqubit (7), repetitions (7), hello (7), world (7), hadamard (6), about (6), learning (6), learn (6), what (6), advanced (6), running (6), install (6), gate (6), device (6), which (6), processors (6), counts (6), measured (6), 2026 (5), com (5), algorithm (5), qiskit (5), one (5), python (5), not (5), specific (5), histogram (5), measure (5), engine (5), core (5), package (5), both (5), framework (4), free (4), research (4), zeitgeist (4), donovan (4), getting (4), started (4), custom (4), time (4), next (4), concepts (4), more (4), first (4), entangled (4), them (4), access (4), can (4), row (4), import (4), need (4), like (4), results (4), operations (4), into (4), grid (4), when (4), abstract (4), 111 (4), 000 (4), superposition (4), will (4), policy (3), amazon (3), team (3), careers (3), glossary (3), case (3), studies (3), frameworks (3), writes (3), pennylane (3), get (3), ibm (3), simulation (3), unitaries (3), beginner (3), setting (3), browse (3), because (3), runs (3), local (3), simulate (3), available (3), topology (3), sampler (3), project (3), through (3), pip (3), counter (3), moments (3), dimensional (3), real (3), their (3), physical (3), correlated (3), just (3), numbered (3), range (3), create (3), entanglement (3), either (3), outcomes (3), always (3), equal (3), corresponds (3), braket (3), cookies (2), experience (2), affiliate (2), see (2), our (2), terms (2), quantumcomputingcourses (2), books (2), podcasts (2), events (2), faq (2), editorial (2), jobs (2), interview (2), certifications (2), salary (2), programming (2), bloch (2), sphere (2), timeline (2), types (2), reference (2), news (2), paths (2), written (2), who (2), industry (2), references (2), tools (2), quantumcomputing (2), email (2), new (2), week (2), paid (2), fast (2), clifford (2), related (2), language (2), level (2), continue (2), these (2), guides (2), coursera (2), edx (2), udemy (2), brilliant (2), deeper (2), has (2), since (2), out (2), have (2), physics (2), other (2), code (2), also (2), open (2), full (2), yourself (2), noise (2), before (2), submitting (2), notice (2), column (2), coordinates (2), actual (2), target (2), specification (2), design (2), match (2), get_device (2), hardware_result (2), build (2), using (2), gridqubits (2), list (2), cirq_google (2), cloud (2), directly (2), includes (2), along (2), sycamore (2), layout (2), outcome (2), returns (2), dictionary (2), where (2), keys (2), integers (2), times (2), probabilistic (2), exact (2), makes (2), parallel (2), steps (2), automatically (2), independent (2), simultaneously (2), targeting (2), col (2), position (2), here (2), equals (2), perfectly (2), pattern (2), expected (2), output (2), creating (2), same (2), correlates (2), frac (2), sqrt (2), but (2), produces (2), later (2), applies (2), creates (2), line (2), chip (2), placement (2), gives (2), prerequisites (2), wave (2), accept, decline, improve, track, performance, cookie, privacy, disclosure, llc, associate, earn, qualifying, purchases, contact, site, talent, pool, post, job, training, questions, cheatsheets, history, docs, compare, maintained, curated, anyone, 241, 220, 112, subscribe, address, worth, taking, changed, spam, unsubscribe, anytime, algorithms, practical, beginners, documentation, aug, updated, glance, page, intermediate, structured, ready, share, yes, was, helpful, quantumzeitgeist, ran, his, 2018, put, subject, down, built, material, there, forced, choice, nobody, should, make, pop, science, hand, waving, end, phd, ramp, had, usually, stopped, working, found, drop, pauli, watch, vector, probabilities, update, instantly, entirely, browser, signup, screen, try, builder, covered, basics, installing, building, simple, introduction, covers, parameterized, patterns, even, without, sets, validate, compatible, particular, uses, instead, must, correspond, positions, tells, pairs, connected, get_sampler, submit, via, name, get_processor, select, its, list_processors, gcp, project_id, connect, service, enabled, currently, limited, approved, partners, programs, workflow, looks, alongside, integrates, client, definitions, describe, connectivity, how, often, occurred, across, encoding, bitstrings, collects, repetition, simulates, execution, including, collapse, statevector, computes, ideal, debugging, container, organizes, grouping, they, execute, ops, arrange, linear, development, worry, summary, objects, methods, used, extend, any, number, adding, 502, 498, shorthand, multiple, once, works, construction, follows, apply, then, subsequent, spread, additional, adds, group, greenberger, horne, zeilinger, extends, resulting, only, appear, never, confirms, vary, inherently, values, roughly, close, 500, 514, 486, converts, count, representing, bitstring, equivalent, shots, collapses, classical, measures, labels, retrieve, flips, after, entangles, controlled, puts, chance, being, value, schedules, manage, timing, figures, assigns, application, would, place, does, entangle, define, simplest, become, probability, requires, followed, phi, installs, standard, plan, classic, states, locally, way, distinctive, carry, information, bit, location, forces, think, constraints, start, map, though, work, most, source, library, writing, simulating, precise, control, over, scheduling, making, natural, fit, near, term, sections, background, needed, basic, variables, functions, loops, write, program, jan, series, home, search, troubleshooting, prep, universities, career, cheat, sheets, migration, comparison, pinball, explore, ocean, tket, pyquil, shor, grover, rigetti, quera, azure, quantinuum, ionq, providers, course, platforms, skip, main, content,


Text of the page (random words):
hello world in cirq skip to main content quantumcomputing courses com courses all courses course platforms coursera edx udemy brilliant hardware providers google quantum ai ibm quantum ionq quantinuum amazon braket azure quantum quera rigetti d wave tutorials all tutorials hello world qiskit hello world cirq hello world pennylane hello world braket quantum gates grover s algorithm shor s algorithm reference all frameworks qiskit cirq pennylane amazon braket pyquil tket d wave ocean q explore learn learning paths prerequisites programming guide case studies glossary books quantum news podcasts tools bloch sphere quantum pinball guides algorithm guide hardware guide qubit types framework comparison migration guide language timeline cheat sheets career events 2026 jobs careers certifications salary guide universities interview prep faq troubleshooting about about team search browse courses home tutorials hello world in cirq cirq beginner free 1 13 in series 20 min read 4 jan 2026 by dr donovan quantum zeitgeist editorial policy hello world in cirq write your first quantum program in cirq create a bell state using gridqubits and moments run it on the cirq simulator cirq quantum circuits bell state ghz state google python prerequisites basic python variables functions loops no quantum physics background needed in this guide 6 sections 01 setting up cirq 02 example 1 bell state 03 example 2 ghz state three qubits 04 key cirq concepts 05 running on google quantum hardware 06 what to learn next cirq is google s open source python library for writing simulating and running quantum circuits it gives you precise control over qubit placement and gate scheduling making it a natural fit for research on near term quantum hardware what makes cirq distinctive is that qubits carry physical placement information gridqubit 0 0 is not just an abstract bit it corresponds to a specific physical location on google s sycamore quantum processor chip this design forces you to think about hardware constraints from the start which produces circuits that map directly to real device topology for getting started though linequbit gives you numbered abstract qubits that work like most other frameworks in this tutorial you will create two classic entangled states the bell state and the ghz state simulate them locally and learn the core cirq concepts along the way setting up cirq install cirq with pip pip install cirq this installs the core cirq package which includes the local simulator and all standard gates if you plan to target google hardware later you will also install cirq google but the core package is all you need for this tutorial example 1 bell state the bell state φ 1 2 00 11 phi rangle frac 1 sqrt 2 00 rangle 11 rangle φ 2 1 00 11 is the simplest example of quantum entanglement two qubits become perfectly correlated when you measure them you always get either both 0 or both 1 with equal probability creating a bell state requires just two gates a hadamard followed by a cnot import cirq define two qubits on a 2d grid q0 cirq linequbit 0 q1 cirq linequbit 1 build the circuit circuit cirq circuit cirq h q0 superposition on qubit 0 cirq cnot q0 q1 entangle q0 and q1 cirq measure q0 q1 key result print bell state circuit print circuit simulate with 1000 repetitions simulator cirq simulator result simulator run circuit repetitions 1000 print n measurement counts print result histogram key result what each line does cirq linequbit 0 and cirq linequbit 1 creates two numbered abstract qubits linequbit assigns each qubit a position on a one dimensional line in a real application targeting google hardware you would use cirq gridqubit row col to place qubits on the chip s two dimensional grid cirq circuit creates a circuit from a list of operations cirq automatically schedules independent operations into parallel moments time steps you do not need to manage timing yourself cirq figures out which gates can run simultaneously cirq h q0 applies the hadamard gate to qubit 0 this puts the qubit into an equal superposition of 0 0 rangle 0 and 1 1 rangle 1 so it has a 50 50 chance of being measured as either value cirq cnot q0 q1 applies the controlled not gate if q0 is 1 1 rangle 1 the gate flips q1 because q0 is in superposition after the hadamard the cnot entangles the two qubits so their outcomes are always correlated cirq measure q0 q1 key result measures both qubits and labels the measurement with the key result you use this key later to retrieve the measurement outcomes simulator run circuit repetitions 1000 runs the circuit 1000 times equivalent to 1000 shots each run collapses the quantum state and produces one classical measurement outcome result histogram key result converts the 1000 measurement results into a count dictionary the keys are integers representing the measured bitstring 0 corresponds to binary 00 both qubits measured 0 and 3 corresponds to binary 11 both qubits measured 1 expected output bell state circuit 0 h m result 1 x m measurement counts counter 3 514 0 486 only two outcomes appear 0 binary 00 and 3 binary 11 you never see 1 binary 01 or 2 binary 10 this confirms that the two qubits are entangled their measurement results are always the same your exact counts will vary because quantum measurement is inherently probabilistic but the two values will be roughly equal each close to 500 example 2 ghz state three qubits a ghz greenberger horne zeilinger state extends entanglement from two qubits to three where the bell state correlates two qubits the ghz state correlates three all three qubits are either all 0 or all 1 when measured the resulting state is 1 2 000 111 frac 1 sqrt 2 000 rangle 111 rangle 2 1 000 111 the construction follows the same pattern as the bell state apply a hadamard to the first qubit to create superposition then use cnot gates from the first qubit to each subsequent qubit to spread the entanglement each additional cnot adds one more qubit to the entangled group import cirq q0 q1 q2 cirq linequbit range 3 circuit cirq circuit cirq h q0 cirq cnot q0 q1 cirq cnot q0 q2 cirq measure q0 q1 q2 key result print ghz state circuit print circuit simulator cirq simulator result simulator run circuit repetitions 1000 print n measurement counts print result histogram key result notice that cirq linequbit range 3 is a shorthand for creating multiple qubits at once it works just like python s range and returns qubits numbered 0 through 2 expected output ghz state circuit 0 h m result 1 x m 2 x m measurement counts counter 0 502 7 498 here 0 equals binary 000 and 7 equals binary 111 all three qubits are perfectly correlated you can extend this pattern to any number of qubits by adding more cnot gates from q0 to each new qubit key cirq concepts here is a summary of the core cirq objects and methods used in this tutorial linequbit i an abstract qubit at linear position i use linequbit for learning and algorithm development when you do not need to worry about physical hardware layout gridqubit row col a qubit at a specific row and column on a two dimensional grid use gridqubit when targeting real hardware since google s quantum processors arrange their qubits in a grid cirq circuit ops a container for quantum operations cirq organizes operations into parallel moments time steps automatically grouping independent gates so they execute simultaneously cirq simulator a local statevector simulator it computes exact results with no noise which makes it ideal for learning and debugging circuits before running on hardware simulator run circuit repetitions n runs the circuit n times and collects measurement results each repetition simulates a full execution including the probabilistic collapse at measurement result histogram key counts how often each measurement outcome occurred across all repetitions returns a counter dictionary where keys are integers encoding the measured bitstrings running on google quantum hardware cirq integrates directly with google s quantum processors through the cirq google package this package includes the hardware client for submitting circuits along with google specific gates like the sycamore gate and device definitions that describe each processor s qubit layout and connectivity install it alongside the core package pip install cirq google to run circuits on actual hardware you need a google cloud project with quantum computing service access enabled this access is currently limited to approved research partners through google s quantum computing programs if you have access the workflow looks like this import cirq import cirq_google connect to the quantum engine with your google cloud project engine cirq_google engine project_id your gcp project list available quantum processors processors engine list_processors print available processors processors select a processor and get its device specification processor engine get_processor processor name device processor get_device build a circuit using gridqubits that match the device topology q0 cirq gridqubit 5 3 q1 cirq gridqubit 5 4 circuit cirq circuit cirq h q0 cirq cnot q0 q1 cirq measure q0 q1 key result submit the circuit to the hardware via the processor s sampler sampler processor get_sampler hardware_result sampler run circuit repetitions 1000 print hardware_result histogram key result notice that the code uses gridqubit with specific row and column coordinates instead of linequbit these coordinates must correspond to actual qubit positions on the target processor the device specification from processor get_device tells you which qubits are available and which pairs are connected so you can design circuits that match the hardware topology even without hardware access you can use cirq google to simulate google specific gate sets and validate that your circuits are compatible with a particular processor before submitting them what to learn next this tutorial covered the basics installing cirq building simple entangled circuits and running them on the local simulator for a deeper introduction that covers custom gates noise simulation parameterized circuits and more advanced patterns continue with our getting started with cirq tutorial try it yourself quantum circuit builder open full screen drop in hadamard pauli s t and cnot gates and watch the state vector and measurement probabilities update instantly it runs entirely in your browser no signup or install written by dr donovan who writes on quantum computing research hardware and industry at quantum zeitgeist dr donovan ran his first quantum circuit on ibm s 5 qubit quantum experience in 2018 and has not put the subject down since he built quantumcomputingcourses com because the material out there forced a choice nobody should have to make pop science hand waving at one end phd level physics with no on ramp at the other and tutorial code that had usually stopped working by the time you found it he also writes on quantum computing at quantum zeitgeist quantumzeitgeist com was this tutorial helpful yes no share ready to go deeper browse structured courses from coursera edx udemy brilliant and more browse courses related tutorials continue learning with these guides advanced gates and custom unitaries in cirq intermediate 13 min read read fast clifford simulation with cirq advanced 15 min read read getting started with cirq beginner 25 min read read next advanced gates and custom unitaries in cirq on this page 01 setting up cirq 02 example 1 bell state 03 example 2 ghz state three qubits 04 key cirq concepts 05 running on google quantum hardware 06 what to learn next at a glance level beginner read time 20 min read language python updated aug 2026 related tutorials advanced gates and custom unitaries in cirq 13 min read fast clifford simulation with cirq 15 min read getting started with cirq 25 min read courses on this cirq tutorials and documentation google quantum ai free practical quantum computing with ibm qiskit for beginners paid quantum computing with qiskit and advanced algorithms paid get one quantum email a week new tutorials courses worth taking and what changed in qiskit cirq pennylane this week no spam unsubscribe anytime email address subscribe 112 courses 220 tutorials 241 glossary terms 26 framework references 34 case studies quantumcomputing courses com free tutorials curated courses framework references and tools for anyone learning quantum computing written and maintained by dr donovan who writes on quantum computing research hardware and industry at quantum zeitgeist learn all courses free tutorials learning paths compare frameworks algorithm guide case studies quantum news reference glossary framework docs hardware guide qubit types history timeline cheatsheets bloch sphere quantum programming careers careers guide salary guide certifications interview questions jobs team training post a job talent pool about about this site editorial policy team faq events 2026 podcasts books contact as an amazon associate i earn from qualifying purchases 2026 hadamard llc quantumcomputingcourses com affiliate disclosure privacy terms cookies we use cookies to improve your experience and track affiliate performance see our cookie policy decline accept
Thumbnail images (randomly selected): * Images may be subject to copyright.GREEN status (no comments)
  • Hacker laptop
  • Dr. Donovan author photo

Verified site has: 88 subpage(s). Do you want to verify them? Verify pages:

1-5 6-10 11-15 16-20 21-25 26-30 31-35 36-40 41-45 46-50
51-55 56-60 61-65 66-70 71-75 76-80 81-85 86-88


The site also has 1 references to external domain(s).

 quantumzeitgeist.com  Verify


Top 50 hastags from of all verified websites.

Supplementary Information (add-on for SEO geeks)*- See more on header.verify-www.com

Header

HTTP/1.1 301 Moved Permanently
Connection close
Content-Length 0
Server Varnish
Retry-After 0
Location htt????/quantumcomputingcourses.com/tutorials/cirq-hello-world
Accept-Ranges bytes
Date Mon, 28 Sep 2026 01:46:34 GMT
X-Served-By cache-rtm-ehrd2290030-RTM
X-Cache HIT
X-Cache-Hits 0
X-Timer S1790559995.882742,VS0,VE0
alt-svc h3= :443 ;ma=86400,h3-29= :443 ;ma=86400,h3-27= :443 ;ma=86400
HTTP/2 200
cache-control public, max-age=0, must-revalidate
content-encoding gzip
content-type text/html; charset=utf-8
etag 3a08171652f2bbce63d24ed2645aa744c4c43d4d3196b30973e4baf5559e70de
last-modified Sat, 12 Sep 2026 20:05:51 GMT
strict-transport-security max-age=31556926
accept-ranges bytes
date Mon, 28 Sep 2026 01:46:35 GMT
x-served-by cache-lcy-egml8630096-LCY
x-cache MISS
x-cache-hits 0
x-timer S1790559995.908477,VS0,VE94
vary x-fh-requested-host, accept-encoding
alt-svc h3= :443 ;ma=86400,h3-29= :443 ;ma=86400,h3-27= :443 ;ma=86400
content-length 16728

Meta Tags

title="Hello World in Cirq"
charset="UTF-8"
name="viewport" content="width=device-width, initial-scale=1"
name="description" content="Write your first quantum program in Cirq, create a Bell state using GridQubits and Moments, run it on the Cirq simulator."
property="og:type" content="article"
property="og:url" content="htt????/quantumcomputingcourses.com/tutorials/cirq-hello-world"
property="og:title" content="Hello World in Cirq | QuantumComputingCourses.com"
property="og:description" content="Write your first quantum program in Cirq, create a Bell state using GridQubits and Moments, run it on the Cirq simulator."
property="og:image" content="htt????/quantumcomputingcourses.com/images/library/Hacker_with_laptop_2K_202608121542.webp"
property="og:image:width" content="1200"
property="og:image:height" content="630"
property="og:locale" content="en_US"
property="og:site_name" content="QuantumComputingCourses.com"
property="article:published_time" content="2026-01-04T00:00:00.000Z"
property="article:author" content="QuantumComputingCourses.com"
name="twitter:card" content="summary_large_image"
name="twitter:title" content="Hello World in Cirq | QuantumComputingCourses.com"
name="twitter:description" content="Write your first quantum program in Cirq, create a Bell state using GridQubits and Moments, run it on the Cirq simulator."
name="twitter:image" content="htt????/quantumcomputingcourses.com/images/library/Hacker_with_laptop_2K_202608121542.webp"
name="theme-color" content="#fffaf3"
name="color-scheme" content="light dark"
name="darkreader-lock"
name="author" content="QuantumComputingCourses.com"
name="google-site-verification" content="AUHneuZfjppbdqvvRkpwjhiFC2kqmW6SfDDJWqAY_rs"

Load Info

page size16728
load time (s)0.165317
redirect count1
speed download101381
server IP 199.36.158.100
* all occurrences of the string "http://" have been changed to "htt???/"