bc
1 program
Added 2025-10-23T08:27:19Z
Model: google/gemini-2.5-proTemp: 0.4
Evidence
Report issue
View issues
Aliases: basic calculator, bench calculator
Provenance: commit 455f5651d6 · authored 2025-10-23T10:27:19+02:00 · model google/gemini-2.5-pro
Sources mentioning this language
6 sources · pl_id:
pl/bcWikipedia infobox ↗
Pulled from the
wikimedia/structured-wikipedia
snapshot — see data/raw/wikipedia_pl_facts.*.jsonl and
pl_fact.csv for the long-table provenance.
| Designed by | Robert Morris · Lorinda Cherry of Bell Labs |
|---|---|
| First appeared | 1975 |
| Homepage | https://www.gnu.org/software/bc/ |
Extensions claimed by this language
1 claim. Each row is one upstream assertion with its strength.
SWH column shows file occurrences with that extension across the entire archive.| Extension | Source | Strength | SWH |
|---|---|---|---|
.bc | pygments | primary | 811.7K files |
Related languages
Real programs from Software Heritage
No SWH evidence indexed yet for this language. (Either the SWH mining hasn't reached this language's extensions, or no matching files exist in the archive.)
Programs collected by LLM agents experimental · unverified
Gathered by LLM agents during the experiment that started this catalogue. They are not verified: the agent names an origin, but a program can be altered or invented — an audit found one attributed to a file that does not exist, in a syntax the language does not have. Prefer the programs archived by Software Heritage above. The catalogue's goal is the languages themselves, grounded in sources (PLDB, Wikipedia, Rosetta Code, …), with real archived programs; these examples may be dropped.
Towers of Hanoi solver
Provenance: commit 455f5651d6 · authored 2025-10-23T10:27:19+02:00 · model google/gemini-2.5-pro · Temp 0.4
/*
*
* Towers of Hanoi
*
* By: P.H. Hirst
*
* hanoi(n) will print the moves to solve the
* Towers of Hanoi puzzle with n disks.
*
* hanoi(n,s,d,u) will print the moves to transfer
* n disks from spire s to spire d using spire u
* as an intermediate.
*
*/
define hanoi(n,s,d,u) {
auto i, os
if (n <= 0) { return }
if (s == 0) { s = 1 }
if (d == 0) { d = 3 }
if (u == 0) { u = 2 }
hanoi(n-1, s, u, d)
os = scale; scale = 0
print "Move disk ", n, " from ", s, " to ", d, "\n"
scale = os
hanoi(n-1, u, d, s)
}