Convert Integers to Unary Base
Convert integers to base one (a run of tally symbols). Runs entirely in your browser, so your data never leaves your device.
0 chars · 0 lines
Output
The result appears here as you type.
How to use Convert Integers to Unary Base
- 1. Paste the integers. Enter one or more non-negative integers, one per line or separated by spaces. Each one determines how many tally symbols appear in its unary output.
- 2. Set the unary symbol and zero output. Type the character to repeat into Unary symbol, such as a tally mark or the digit 1, and set Output for zero to control what appears when an integer is exactly zero.
- 3. Copy the unary strings. Copy the resulting runs of symbols, one per input integer, and paste them wherever a tally-style base-one representation is useful.
When to use Convert Integers to Unary Base
Convert Integers to Unary Base writes each whole number as a run of repeated tally symbols, the simplest possible number system where the value is literally the count of marks. Convert Integers to Unary Base is mostly used for teaching, puzzles and esoteric formats.
- Teaching the concept of a number base. Before introducing binary or hexadecimal, a lesson on positional versus non-positional counting starts with unary, where 5 becomes five tally marks in a row.
- Generating input for an esoteric programming exercise. Some programming puzzles or esoteric languages define input in unary form. Convert your decimal test values into the required run of symbols here.
- Building a simple visual counter. A tally-style display, like a scoreboard using stick marks instead of digits, needs each count converted to a run of symbols before rendering.
- Exploring why unary is impractical for large numbers. Demonstrating how quickly unary representations grow compared to decimal or binary is easier when students can generate the tally string for a real number and see its length.
Examples
Five as unary
Input
5
Output
11111
Custom symbol
Input
3
Output
***
About the Convert Integers to Unary Base tool
Convert Integers to Unary Base runs as plain JavaScript in your browser tab, with no server behind it. Convert integers to base one (a run of tally symbols). Whatever you put in stays on your device from start to finish.
The tool is part of EditSafely's Integer Tools section, 133 single-purpose utilities built around the same idea: open the page, get the result, keep your data to yourself.
You can shape the output with 2 settings, including Unary symbol and Output for zero, and the result refreshes the moment you change one. 2 worked examples further down the page show exactly what the tool produces for real inputs.
That local-first design has practical benefits beyond privacy. The tool keeps working on a flaky connection once the page has loaded, results are instant because nothing round-trips to a server, and it is safe to use with confidential material.
Frequently asked questions
Does Convert Integers to Unary Base cost anything?
Yes, it is completely free. All 2,658 tools on EditSafely work without an account, a subscription or usage limits.
Is it safe to paste sensitive or confidential data?
No data leaves your device. The whole tool is JavaScript that runs inside your browser tab, so there is no upload, no server-side processing and no log of what you did. If you disconnect from the internet after the page loads, it keeps working.
How much text can I process at once?
There is no fixed limit. Because the work happens on your own device rather than on a shared server, the practical ceiling is your machine's memory, which comfortably handles inputs far larger than typical online tools allow.
Do I need to sign up or install anything?
Nothing to install and no account needed. Open the page in any up-to-date browser, including on a phone or tablet, and the tool is ready.
How do I use the result?
The output panel has a one-click copy button, and you can keep refining the input while you work; the result updates in place as you type.