50
\$\begingroup\$

We've got a lot of questions asking how to count the bytes in different situations. This question is here to put them all in one spot.

General questions

How to count "interactive" answers and flags (revised to: Let's solve the flag problem once and for all)
How to count REPLs
How to count multiple files
How to count lambdas
How to count whitespace
How to count shebangs
How to count "expanded text"
How to count encodings
How to count language-switch flags

Language/feature-specific questions

7
Algodoo
APL
Assembly
Box 256
Desmos.com
Folders
LabView
Lego WeDo
Minecraft
PHP GET
PHP -r/-R/-F
Piet
Scratch
TI-Basic
VBA immediate Window
VB.NET auto-includes
Vim
Vitsy


Return to FAQ index

\$\endgroup\$
  • 16
    \$\begingroup\$ Thanks for this. I think this is incredibly helpful and will be a great place to point new users to. \$\endgroup\$ – Alex A. Sep 22 '16 at 20:28
  • \$\begingroup\$ @AlexA. For some reason, there is no FAQ section on the right side. \$\endgroup\$ – Erik the Outgolfer Sep 24 '16 at 7:10
  • \$\begingroup\$ PHP GET is actually a standard accepted input method: meta.codegolf.stackexchange.com/a/7591/14732 (current score: +14 -5). Also, POST would fall in the same category as GET. \$\endgroup\$ – Ismael Miguel Sep 28 '16 at 14:27
  • \$\begingroup\$ @IsmaelMiguel Ok? This question isn't about what is/isn't allowed, but rather how we count the bytes. The PHP GET question about is specifically how we count the bytes with PHP GETs. \$\endgroup\$ – Nathan Merrill Sep 28 '16 at 14:36
  • \$\begingroup\$ @NathanMerrill The accepted answer in the PHP GET link, in short, says that PHP GET isn't an accepted input method and that the question doesn't make sense. \$\endgroup\$ – Ismael Miguel Sep 28 '16 at 14:50
  • \$\begingroup\$ @IsmaelMiguel the question is still valid, but the answer is out of date. I'd post a comment (or a new answer). \$\endgroup\$ – Nathan Merrill Sep 28 '16 at 14:51
  • \$\begingroup\$ @NathanMerrill That's where I was trying to get, The answer is old and (now) is wrong as well. \$\endgroup\$ – Ismael Miguel Sep 28 '16 at 15:30
  • \$\begingroup\$ How do you count poyglots for languages that normally use different encodings? \$\endgroup\$ – Pavel Dec 7 '16 at 19:37
  • 2
    \$\begingroup\$ @ГригорийПерельман: You find a sequence of bytes that works in all the programs, and then take the number of bytes. The various languages may well interpret each interpret this sequence as a different sequence of characters (so typically you'd present one of the programs as the "main" one and then say what the other languages see in your explanation). \$\endgroup\$ – user62131 Mar 26 '17 at 15:09

You must log in to answer this question.

Browse other questions tagged .