8
\$\begingroup\$

Based on How high can you count? let us give an advantage to the polyglot people.

Challenge:

Your task is to write as many programs / functions / snippets as you can, where each one outputs / prints / returns an integer. The first program must output the integer 1, the second one 2 and so on.

You can not reuse any characters between the programs. So, if the first program is simply: 1, then you may not use the character 1 again in any of the other programs. Note: It's allowed to use the same character many times in one program.

You can only use a programming language once. So every number must be in a different programming language.

Scoring:

The winner will be the submission that counts the highest. In case there's a tie, the winner will be the submission that used the fewest number of bytes in total.

Rules:

  • You can only use a language for one integer - after that you cannot reuse the language
  • Snippets are allowed!
  • To keep it fair, all characters must be encoded using a single byte in same encoding in the languages you choose.
  • The output must be in decimal. You may not output it with scientific notation or some other alternative format. Outputting floats is OK, as long as all digits that are shown behind the decimal point are 0. So, 4.000 is accepted. Inaccuracies due to FPA is accepted, as long as it's not shown in the output.
  • ans =, leading and trailing spaces and newlines etc. are allowed.
  • You may disregard STDERR, as long as the correct output is returned to STDOUT
  • You may choose to output the integer to STDERR, but only if STDOUT is empty.

Note: Explanations are encouraged!

\$\endgroup\$
6
  • \$\begingroup\$ I suggest you remove the tag polyglot because the code is not being run in multiple languages, but rather each program/snippet is run individually in each language. \$\endgroup\$
    – user41805
    Jun 5, 2017 at 7:50
  • \$\begingroup\$ Also, do all the languages have to have the same encoding? \$\endgroup\$
    – user41805
    Jun 5, 2017 at 7:52
  • \$\begingroup\$ What if the same character is encoded differently in different languages? E.g. 1 is encoded as 0x65 in language A, and as 0x67 in language B. Can I then use the character 1 in both languages because they map to different bytes? \$\endgroup\$
    – Luke
    Jun 5, 2017 at 7:53
  • \$\begingroup\$ @KritixiLithos As far as I know, only the hex bytes matter. \$\endgroup\$
    – Okx
    Jun 5, 2017 at 7:53
  • \$\begingroup\$ For future reference, these types of challenges which ask for individual programs in multiple languages are called rosetta-stone \$\endgroup\$
    – Beta Decay
    Jun 5, 2017 at 8:37

1 Answer 1

8
\$\begingroup\$

GS2, 3var, Alphuck, brainf***, Numberwang, evil, ;#+, Charcoal, Retina, wsf, Jelly, Beeswax, CJam, Fourier, Fireball, M, Pushy, MATL, Brain-Flak, Convex, COW, Mouse-79, Mouse-98, Mouse-2002, Pyke, Neim, JavaScript, Braingolf, Japt, SOGL, score 31

All are encoded as hex bytes in either ASCII or the language's native encoding

GS2 - 1: 01 01
3var - 2: 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64 64
Alphuck - 3: 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65 65
brainf*** - 4: 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b
Numberwang - 5: 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39 39
Evil - 6: 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61 61
;#+ - 7: 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b 3b
Charcoal - 8: b8
wsf - 9: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
Jelly - 10: 85
Beeswax - 11: 50 50 50 50 50 50 50 50 50 50 50
CJam - 12: 43
Retina - 13: 0a 2e 2e 2e 2e 2e 2e 2e 2e 2e 2e 2e 2e 2e 0d 0a 2e
Fourier - 14: 5e 5e 5e 5e 5e 5e 5e 5e 5e 5e 5e 5e 5e 5e
Fireball - 15: 46
M - 16: 96
Pushy - 17: 54 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 74 7e
MATL - 18: 32 51 51 51 51 51 51 51 51 51 51 51 51 51 51 51 51
Brain-Flak - 19: 28 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 28 29 29
Convex - 20: 4b
COW - 21: 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f 4d 6f 4f
Mouse-79 - 22: 57
Mouse-98 - 23: 58
Pylons - 24: 34 21
Mouse-2002 - 25: 5a
Pyke - 26: 4e 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68 68
Neim - 27: f9
JavaScript - 28: 30 78 31 63
Braingolf - 29: 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c 6c
Japt - 30: c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4 c4
SOGL - 31: 41 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49

More to come :)

also if i was allowed to use any language as many times as i want i would be able to get ~200

\$\endgroup\$
8
  • 3
    \$\begingroup\$ Might be worth showing both the actual characters and the hex bytes, makes it easier to see what characters have already been used. Also if you haven't already used ASCII l, 13 ls in Braingolf will output 12 \$\endgroup\$
    – Mayube
    Jun 5, 2017 at 8:40
  • \$\begingroup\$ @Mayube Thanks for that braingolf tip :) \$\endgroup\$
    – Okx
    Jun 5, 2017 at 8:55
  • \$\begingroup\$ if you find an easier way to make 12 in another language, but struggle with a different number later on, n+1 ls in Braingolf will always output n, so for example 43 ls will output 42 \$\endgroup\$
    – Mayube
    Jun 5, 2017 at 8:57
  • \$\begingroup\$ @Mayube I noticed. \$\endgroup\$
    – Okx
    Jun 5, 2017 at 8:58
  • \$\begingroup\$ SOGL programs for 31: 41 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 (AIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII) or 27 0e () or 8c b7 52 05 fe 6a (∫ΠR⁵‘j). \$\endgroup\$
    – dzaima
    Jun 5, 2017 at 14:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.