Switch guideC++ editor

C++ EDITOR

A C++ scratchpad for small, explained examples.

Keep a standard-library pattern, a header fragment, or an example from a code review. C++ mode gives your source syntax highlighting while the notebook keeps it saved locally.

Open editor

Free to use · No account needed · Saved in this browser

ready.cpp C++
#include <algorithm>
#include <vector>

int count_ready(const std::vector<int>& states) {
  return static_cast<int>(
    std::count(states.begin(), states.end(), 1)
  );
}
A short C++ standard-library example with the include files it depends on.Try this example

EDIT IN YOUR BROWSER

Your local draft

The notebook’s editing tools, right here. Save to notebook when you want a named copy.

Open full editor

Enable JavaScript to edit here, or open the full editor above. The example and guide are always available.

This draft is shared with the full editor for this task and stays separate from named notes. Export a copy or save to notebook to include it in a notebook backup. This editor page and its tools reopen offline after the editor reports readiness. Informational and privacy guides need a connection.

A FEW SIMPLE STEPS

Get started

  1. Create a note and choose C++ or search for .cpp in the language chooser.
  2. Paste your source and keep the includes or standard-version assumptions nearby.
  3. Edit, search, or compare the fragment with another revision.
  4. Download or copy the source to compile and test in your project.

Open editor takes you to the draft on this page. Paste or open a source file, or choose Try this example. Save to notebook keeps a named copy with your notes. Your workspace style stays unchanged.

Save enough context to reuse a fragment

A C++ snippet often depends on an include, a type, or a language standard. Keep those details in the same note so you can distinguish an isolated example from code ready to paste into a project.

Use the language chooser’s C++ mode for .cpp source. Line numbers, find and replace, tags, and comparison panes help when you are reading or revising an example.

Compile and check in your toolchain

The notebook does not run a C or C++ compiler, link libraries, resolve build flags, or execute a binary. Source highlighting is not a correctness check.

Review any formatting changes and download the source for your actual toolchain. Your project’s compiler settings and tests remain the place to check portability and behavior.

A few questions

Is this a browser C++ compiler?

It is a source editor and snippet notebook. It does not compile C++, provide a debugger, or run binaries.