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

Comments on Output 256 in many different ways

Parent

Output 256 in many different ways

+13
−0

Challenge

Write as many functions, programs, or snippets of code, that result in 256. Your score is the number of separate solutions submitted in an answer.

The challenge? The characters used in one solution must not appear in any other solution. That is, there is no character used in more than one program.

Notes

  • The bytes of the solution, in the encoding used by the interpreter/compiler running the solution, are what is used for distinctness checking. For example, if the answer is scored in UTF-8, one solution containing á means no other can contain é as both share the 0xC3 byte, but an SBCS containing both would allow it.
  • Solutions must have at least one character (otherwise the empty program giving 256 would result in a score of $\infty$).
  • The usage of bytes for scoring means that the maximum score ever achievable is 256 (but getting that would mean having a language where every character prints 256).
  • The result can be either a number, that equals to 256 (or differs from it by a maximum of 0.001), or a string representing it in decimal form, possibly ending with .0.
  • Each submission can be of a different type (function, program, snippet), and can return in a different format (return value, STDOUT, console, etc.)
  • Yes, snippets of code are allowed. So 256 is a valid solution in most languages.
  • Highest score wins!
History
Why does this post require attention from curators or moderators?
You might want to add some details to your flag.
Why should this post be closed?

1 comment thread

General comments (6 comments)
Post
+5
−0

Husk, 9 solutions

1. Classic

256

Try it online!

2. Squaring

□□4

Try it online!

3. Incrementing

→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→1

Try it online!

4. Decrementing

←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←300

Try it online!

5. String Length

L"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

Try it online!

6. Codepoint

c'Ā

Try it online!

7. Powers of ½

\!7tݽ

Try it online!

8. Doubling

DDDDD8

Try it online!

9. Counting zeroes

#¬ΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘΘø

Try it online!

History
Why does this post require attention from curators or moderators?
You might want to add some details to your flag.

1 comment thread

General comments (2 comments)
General comments

Skipping 1 deleted comment.

Razetime‭ wrote about 4 years ago

thanks, changed it.

dzaima‭ wrote about 4 years ago

Yep, seems fine now. (fwiw you could save a 0 with ←←…←←333)