Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »
Challenges

Post History

60%
+1 −0
Challenges Digit balanced numbers

Uiua, 10 bytes (SBCS) Counts all digit occurrences and checks the count array is all-equal (for which there is no short idiom in Uiua yet except for that deduplicate-length-equal-to-one and simila...

posted 6mo ago by ojdo‭

Answer
#1: Initial revision by user avatar ojdo‭ · 2026-03-10T12:24:32Z (6 months ago)
# [Uiua](https://uiua.org/), 10 bytes (SBCS)

Counts all digit occurrences and checks the count array is all-equal (for which there is no short idiom in Uiua yet except for that deduplicate-length-equal-to-one and similar gymnastics).

```uiua
=1⧻◴⊕⧻⊸⊛°⋕
```

[Uiua pad this online](https://uiua.org/pad?src=0_19_0-dev_1__eJxtkD0KAjEQRvs9xRwh85dsCts9muDKgs0iYrtga2Eh2HmUOYlkIRAmpkoeL983yQR2vMAB7fGx68vmtWzmt83379PO62DLZtvNTgsgTIDuTORAHjvDK8TiCIvGDvUWqzokMXoLqaSlMfetOw7eRyJm6WIKJ2b2nIkJCT1XURURP2Cuq-EBJkip_adCNLZ3CymDOUTYoVrg83b2p7m-17fVnPZ_dj8gBeLAww8ZFeGY)

### Explanation

```uiua
=1⧻◴⊕⧻⊸⊛°⋕    112233        example input
          °⋕    "112233"      unparse: convert to character array
       ⊸⊛      [0 0 1 1 2 2] "112233" push unique index per element,
                                       keep argument on stack
    ⊕⧻         [2 2 2]       determine per-group length: count array
   ◴            [2]           deduplicate count array
  ⧻             1             determine its length
=1              1             equal to 1?
```