[Question]
  [
Given the name of a Stack Exchange site which doesn't have their own design yet, decide how many ASCII characters (non-ASCII ones are counted separately) are there on their icons. Your code should distinguish these 4 cases:
1 character:
```
Astronomy
Beer
Freelancing
Health
History
Law
Music: Practice & Theory
Parenting
The Great Outdoors
Writers
```
2 characters:
```
3D Printing
Amateur Radio
Biblical Hermeneutics
Bitcoin
Board & Card Games
Buddhism
Chinese Language
Coffee
Community Building
Computational Science
Computer Graphics
Data Science
Earth Science
Ebooks
Economics
Emacs
Engineering
Expatriates
French Language
Gardening & Landscaping
Genealogy & Family History
German Language
Hardware Recommendations
Hinduism
Homebrewing
Islam
Italian Language
Japanese Language
Joomla
Lifehacks
Martial Arts
Mathematics Educators
Motor Vehicle Maintenance & Repair
Music Fans
Mythology
Open Data
Personal Productivity
Pets
Philosophy
Physical Fitness
Politics
Portuguese Language
Project Management
Puzzling
Quantitative Finance
Reverse Engineering
Robotics
Russian Language
Software Quality Assurance & Testing
Software Recommendations
Sound Design
Space Exploration
Spanish Language
Sports
Startups
Sustainable Living
Tridion
Vi and Vim
Video Production
Windows Phone
Woodworking
Worldbuilding
```
3 characters:
```
Cognitive Sciences
elementary OS
Ethereum
History of Science and Mathematics
Linguistics
Open Source
Programming Puzzles & Code Golf
Signal Processing
Tor
```
Non-ASCII:
```
Anime & Manga
Arduino
Aviation
Chess
CiviCRM
Poker
```
Excluded in this challenge for having non-ASCII characters in their names:
```
LEGO® Answers
Русский язык
```
Your code should output a consistent distinct value for each of the 4 sets. Each output (or its string representation for non-string values returned from a function) should be no more than 10 bytes, not counting the optional trailing newline.
You can create multiple pieces of code in the same language. The output of your submission is considered to be the output of each piece of code concatenated in a fixed order (so you can use Regex).
Shortest code wins.
  
[Answer]
## CJam, ~~50~~ ~~48~~ 45 bytes
```
l22b391"þÁ "+{i%}/"Yª>Þÿ9cîÂcVáòe~"322b4b=
```
There's unprintable characters in the strings above, which can be obtained by the snippets
```
[254 193 160]:c
[89 170 62 222 30 255 20 57 99 238 194 99 86 225 242 101 126 20]:c
```
This also shows that the code points are all below 256. Output is `0` for 1 letter, `1` for 2 letters, `2` for 3 letters and `3` for non-ASCII.
The program simply converts the input string to a base 22 number, performs a series of modulos to reduce the number down, before performing a lookup from a base-4 encoded table.
[Try it online](http://cjam.aditsu.net/#code=l22b391%22%C3%BE%C3%81%C2%A0%22%2B%7Bi%25%7D%2F%22Y%C2%AA%3E%C3%9E%1E%C3%BF%149c%C3%AE%C3%82cV%C3%A1%C3%B2e~%14%22322b4b%3D&input=Anime%20%26%20Manga) | [Test suite](http://cjam.aditsu.net/#code=87%7B%0A%0Al22b391%22%C3%BE%C3%81%C2%A0%22%2B%7Bi%25%7D%2F%22Y%C2%AA%3E%C3%9E%1E%C3%BF%149c%C3%AE%C3%82cV%C3%A1%C3%B2e~%14%22322b4b%3D%0A%0A%7D*%5DN*&input=Astronomy%0ABeer%0AFreelancing%0AHealth%0AHistory%0ALaw%0AMusic%3A%20Practice%20%26%20Theory%0AParenting%0AThe%20Great%20Outdoors%0AWriters%0A3D%20Printing%0AAmateur%20Radio%0ABiblical%20Hermeneutics%0ABitcoin%0ABoard%20%26%20Card%20Games%0ABuddhism%0AChinese%20Language%0ACoffee%0ACommunity%20Building%0AComputational%20Science%0AComputer%20Graphics%0AData%20Science%0AEarth%20Science%0AEbooks%0AEconomics%0AEmacs%0AEngineering%0AExpatriates%0AFrench%20Language%0AGardening%20%26%20Landscaping%0AGenealogy%20%26%20Family%20History%0AGerman%20Language%0AHardware%20Recommendations%0AHinduism%0AHomebrewing%0AIslam%0AItalian%20Language%0AJapanese%20Language%0AJoomla%0ALifehacks%0AMartial%20Arts%0AMathematics%20Educators%0AMotor%20Vehicle%20Maintenance%20%26%20Repair%0AMusic%20Fans%0AMythology%0AOpen%20Data%0APersonal%20Productivity%0APets%0APhilosophy%0APhysical%20Fitness%0APolitics%0APortuguese%20Language%0AProject%20Management%0APuzzling%0AQuantitative%20Finance%0AReverse%20Engineering%0ARobotics%0ARussian%20Language%0ASoftware%20Quality%20Assurance%20%26%20Testing%0ASoftware%20Recommendations%0ASound%20Design%0ASpace%20Exploration%0ASpanish%20Language%0ASports%0AStartups%0ASustainable%20Living%0ATridion%0AVi%20and%20Vim%0AVideo%20Production%0AWindows%20Phone%0AWoodworking%0AWorldbuilding%0ACognitive%20Sciences%0Aelementary%20OS%0AEthereum%0AHistory%20of%20Science%20and%20Mathematics%0ALinguistics%0AOpen%20Source%0AProgramming%20Puzzles%20%26%20Code%20Golf%0ASignal%20Processing%0ATor%0AAnime%20%26%20Manga%0AArduino%0AAviation%0AChess%0ACiviCRM%0APoker)
[Answer]
# Retina, ~~146~~ ~~136~~ ~~134~~ ~~130~~ ~~124~~ ~~107~~ 102 bytes
```
A\w*i|Che|CR|ke
4
my|Be|lan|^H.*y$|lt|aw|:|Pa|Ou|Wr
1
gn.|^e|Et|^H.*S|gui|rc|lf|To
2
.*(\d).*
$1
..+
3
```
Thanks @Sp3000 for golfing off 4 bytes!  
Thanks @Mwr247 for golfing off 17 bytes by letting me use regexes from [his answer](https://codegolf.stackexchange.com/a/74706/48836)!  
Thanks @jimmy23013 for golfing off 5 bytes by reminding me that I can change output values!
The output is 1, 3, 2, and 4 for 1-char, 2-char, 3-char, and non-ASCII, respectively.
Version with all testcases has edits in few places to make it work with multiple lines.
[Try it online!](http://retina.tryitonline.net/#code=QVx3Kml8Q2hlfENSfGtlCjQKbXl8QmV8bGFufF5ILip5JHxsdHxhd3w6fFBhfE91fFdyCjEKZ24ufF5lfEV0fF5ILipTfGd1aXxyY3xsZnxUbwoyCi4qKFxkKS4qCiQxCi4uKwoz&input=ZWxlbWVudGFyeSBPUw)  
[Try it online with all testcases!](http://retina.tryitonline.net/#code=bWBBXHcqaXxDaGV8Q1J8a2UKNAptYG15fEJlfGxhbnxeSC4qeSR8bHR8YXd8OnxQYXxPdXxXcgoxCm1gZ24ufF5lfEV0fF5ILipTfGd1aXxyY3xsZnxUbwoyCi4qKFxkKS4qCiQxCi4uKwoz&input=QXN0cm9ub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aWNzClJ1c3NpYW4gTGFuZ3VhZ2UKU29mdHdhcmUgUXVhbGl0eSBBc3N1cmFuY2UgJiBUZXN0aW5nClNvZnR3YXJlIFJlY29tbWVuZGF0aW9ucwpTb3VuZCBEZXNpZ24KU3BhY2UgRXhwbG9yYXRpb24KU3BhbmlzaCBMYW5ndWFnZQpTcG9ydHMKU3RhcnR1cHMKU3VzdGFpbmFibGUgTGl2aW5nClRyaWRpb24KVmkgYW5kIFZpbQpWaWRlbyBQcm9kdWN0aW9uCldpbmRvd3MgUGhvbmUKV29vZHdvcmtpbmcKV29ybGRidWlsZGluZwpDb2duaXRpdmUgU2NpZW5jZXMKZWxlbWVudGFyeSBPUwpFdGhlcmV1bQpIaXN0b3J5IG9mIFNjaWVuY2UgYW5kIE1hdGhlbWF0aWNzCkxpbmd1aXN0aWNzCk9wZW4gU291cmNlClByb2dyYW1taW5nIFB1enpsZXMgJiBDb2RlIEdvbGYKU2lnbmFsIFByb2Nlc3NpbmcKVG9yCkFuaW1lICYgTWFuZ2EKQXJkdWlubwpBdmlhdGlvbgpDaGVzcwpDaXZpQ1JNClBva2Vy)
[Answer]
# Javscript ES6, ~~342~~ ~~339~~ ~~330~~ 327 bytes
```
a=>{for(c of "9As4BebFr6He7Hi3LaoMu9PaiTh7Wrzb3DdAmlBi7BiiBo8BugCh6CoiColCohCocDadEa6Eb9Ec5EmbEnbExfFrnGaqGefGeoHa8HibHo5IsgIthJa6Jo9LicMalMayMoaMu9My9OplPe4PeaPhgPh8PojPoiPr8PukQujRe8RogRu10SooSocSohSpgSp6Sp8StiSu7TraVigVidWibWodWoziCodel8EtyHibLibOpvPrhSi3To".split`z`)if(~c.indexOf(a.length.toString(36)+a[0]+a[1]))return c}
```
Returns a long string starting with `9` for one character, a different long string starting with `b` for two, a third string starting with`i` for three, and simply `undefined` for non-ascii.
[Answer]
## PowerShell, ~~212~~ 181 bytes
```
$a=-join$args[0][0,2,-1];$b="Aty,Ber,Feg,Hah,Hsy,Lww,Msy,Prg,Tes,Wis,Cgs,eeS,Ehm,Hss,Lns,Oee,Pof,Sgg,Trr,Aia,Ado,Ain,Ces,CvM,Pkr".IndexOf($a);(((1,3)[$b-ge40],4)[$b-ge76],2)[$b-lt0]
```
I found that if you take the first, third, and last characters of each of the possible entries (`[0,2,-1]` when zero-indexed), we obtain a unique three-letter string for each entry. We then are simply using a string-based lookup to determine which one we have.
Takes input `$args[0]`, and applies the above unique-ness function, saves as `$a`.
This is then sent through our lookup list via `.IndexOf($a)` and the result stored in `$b`. Then, we go through a pseudo-ternary that indexes based on the value of `$b` to output the appropriate value.
Outputs `1`, `2`, `3`, and `4` for one-character, two-character, three-character, non-ASCII, respectively.
Edit - discovered that `[0,2,-1]` creates a unique three-character string for each entry, saving 31 bytes
[Answer]
# JavaScript (ES6), 108 bytes
```
a=>[/A\w*i|Che|CR|ke/,/my|Be|lan|^H.*y$|lt|aw|:|Pa|Ou|Wr/,/gn.|^e|Et|^H.*S|gui|rc|lf|To/].map(b=>+b.test(a))
```
Creates an array composed of regex matches unique to each of the three smallest groups (1 character, 3 character, and non-ascii), then maps a test on the data for each array. When the output is stringified, it evaluates to `1,0,0` for non-ascii, `0,1,0` for 3 characters, `0,0,1` for 1 character, and `0,0,0` for 2 characters.
[Answer]
# [Jelly](https://github.com/DennisMitchell/jelly), 41 bytes
```
ȷ;€ȷḥ€ɠḋ“¥ẏ⁻ỵŻŀ]Ḥ6Iɠçịƥṃƈ=ẈQk®bȷƥ!?’b5¤%5
```
[Try it online!](https://tio.run/##AWIAnf9qZWxsef//yLc74oKsyLfhuKXigqzJoOG4i@KAnMKl4bqP4oG74bu1xbvFgF3huKQ2Scmgw6fhu4vGpeG5g8aIPeG6iFFrwq5iyLfGpSE/4oCZYjXCpCU1//9QdXp6bGluZw "Jelly – Try It Online")
Full program: input from standard input, output to standard output. Output is 1/2/3/0 for 1 character / 2 characters / 3 characters / non-ASCII.
## Discussion
Hey, I found another question where my algorithm for automatically generating answers to "map this input to that output" questions beats all the existing answers. So here we go.
I used [this generator](https://tio.run/##xVZNbxRHEL3vr2itBNoVi2ODOASLw2LsNRYbHBvZSoBEvTO9M23PdI/6w@vlRCJFOXDjxCGRckhuUaSIgEGRcjBCIj/D/iObV92z6zVE5Bit5emPquqqV6@qe08UxXgyOX38w81CW6tLNpSFE4YJlehUmIVGo2syXwrl7PXG8XN2gxXSOqaHTKrKO8taXI2ZG1ei3WmcfvPHnECijRG20iqVKmPau3@RfwF55csBToRGBRfkoBBnwqWHrYFglZGlaLPLLPVVIRPuhGXcCJzhlRMp0yoRHcZVysbas5KPGU9TJg6d4TNjUtGmgU6qS46Zy7kLVpQ4gAPewpAcBgsjaXPy7yX82yCM4IHODC@jUkQHLqjaOow7TVN8RQZjwbxghqtMsMWFha8o1pbxCkoOLpSVRJwOUXWY1fAAZysdYs10MRRpgOfoP4//6HlTp2ofW3QAXACIhlISzXTYAHsheG5ZxU1IHhkbSsWL6cltUOEeFkt@KEtfzmWtJoK0yHwpKRs4dWlxcZGc0gYsooWS74tgtXZmGhCHlnNFDFtCtrVHOU/yEAkpWJGAQ1OnXG6EYO@OLBmFMjcUfu3NQBR6RBszdWmnjk8TBdjYNs/EOUg7bJQLReB0iGtgO6Q@RP5MDAxxOTIG/tTlMVM8gy4TShhOiJyvLnj0mXbievCP5ZwOsyUviuB3IihWZBI0xflDLgtkq4OsiRizxdQjcGDqjDwExqw1EAlHDmufMbJsILPLAsUHAgy4pVpRoLmVWtn21Bj5WggeKjSVmUTuI5GgfAYq7XKwqvEFSiOBvSFODWHCN09lGNy2cEh5hDHukE8hj1SGHPQeRZp8Ms0@l4EVTSOMLopmDVoA5/Txjw20mo3l029/fXd08uoXfI9fswtgdAONqkRN9EPgrd5aC8KMqI6NdofR7Pj5m@@h8fbpyetnYZk9@Kg8ivz4xcHp779R99r98kzv@KW5YZ1pgfEt6mmtst1eQEMJ6fg60WI4lIlE6lvthUIO8bm0BKXAgpYRFTQXgh7UMC14IlpN1uw0m212iTVPXn3XxNfQeH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apNnE3z8 "Jelly – Try It Online") (which I wrote myself) in order to automatically generate this output. For information on the underlying algorithm and how it works, see [this answer](https://codegolf.stackexchange.com/a/214222) and [this answer](https://codegolf.stackexchange.com/a/220588).
This question isn't an ideal fit for the algorithm in question, incidentally. There are two issues which mean that it could well be beatable.
The first issue is that 4 (the number of possible outputs) is not a prime number. The algorithm *itself* doesn't technically require the number of outputs to be prime, just a prime power (because we need a finite field of the appropriate size). 4 is a prime power (2²), so it would be an ideal fit for the question. However, Jelly doesn't have any builtins for operating on **GF**(4), so we're using **GF**(5) instead, which multiplies the size of our long constant by a factor of log(5)/log(4), an increase of about 16%.
The second issue is that 2 is an overwhelmingly common output, with most of the inputs mapping to it. The algorithm doesn't care about this at all, and works equally well with any distribution of outputs. However, an output that *did* care about this fact could probably take advantage of it in order to use a shorter constant string. Although it's easy to imagine what such an algorithm could look like (and it could use almost the same program shell), I can't think of any efficient way to calculate the string constant that most of the program is built around.
Of course, there's also the fact that the total amount of data required is so small that the overhead of the decompressor is rather notable, and a less efficient algorithm could beat it simply by needing a smaller amount of boilerplate!
So I imagine there's scope for improvement here, although I can't immediately see how. It's still interesting to see a machine-generated solution beating all the human-written solutions, though.
## Explanation
```
ȷ;€ȷḥ€ɠḋ“…’b5¤%5
ȷ;€ȷ               Generate 1000 different (arbitrary) hash configurations
    ḥ              Hash
      ɠ              standard input
     €               using each of the hash configurations
       ḋ           Take the dot product of the resulting vector of 1000 hashes
             ¤       with
        “…’b5        a particular list of numbers in the range 0…4 inclusive
              %5   {The output is} that dot product, modulo 5
```
The long list of numbers is chosen to give the correct output for every input (by asking a computer, specifically my generator written in a mix of Jelly and Sage, to find a short list that happens to give the correct input/output mapping).
]