g | x | w | all
Bytes Lang Time Link
260Raku Perl 6 rakudo240803T181842Zbb94
124Jelly210608T224102ZNick Ken
265JavaScript ES6210603T173942ZArnauld
11705AB1E210604T083545Zovs
194Jelly210603T140810Zhyper-ne

Raku (Perl 6) (rakudo), 260 bytes

{2 min+(.match(/^(\d|a<[cglmrstu]>|b<[aehikr]>?|c<[adeflmnorsu]>?|d<[bsy]>|e<[rsu]>|f<[elmr]>?|g<[ade]>|h<[efgos]>?|in|ir?|kr?|l<[airuv]>|m<[cdgnot]>|n<[abdehiop]>?|os?|og|p<[abdmortu]>?|r<[abefghnu]>?|s<[bcegimnr]>?|t<[abcehilms]>|u|v|w|yb?|xe|zn|zr)+$/):ex)}

Attempt This Online!

Explanation

{2 min+(.match(/^(...)+$/):ex)}­⁡​‎‎⁡⁠⁤⁤‏⁠‎⁡⁠⁢⁡⁡‏⁠‎⁡⁠⁢⁡⁢‏⁠‎⁡⁠⁢⁡⁣‏⁠‎⁡⁠⁢⁡⁤‏⁠‎⁡⁠⁢⁢⁡‏⁠‎⁡⁠⁢⁢⁢‏⁠‎⁡⁠⁢⁢⁣‏⁠‎⁡⁠⁢⁢⁤‏⁠‎⁡⁠⁢⁣⁡‏‏​⁡⁠⁡‌⁢​‎‎⁡⁠⁣⁡‏⁠‎⁡⁠⁣⁢‏⁠‎⁡⁠⁣⁣‏⁠‎⁡⁠⁣⁤‏⁠‎⁡⁠⁤⁡‏⁠‎⁡⁠⁤⁢‏⁠‎⁡⁠⁤⁣‏⁠‎⁡⁠⁢⁣⁢‏⁠‎⁡⁠⁢⁣⁣‏⁠‎⁡⁠⁢⁣⁤‏⁠‎⁡⁠⁢⁤⁡‏‏​⁡⁠⁡‌⁣​‎‎⁡⁠⁢⁣‏⁠‎⁡⁠⁢⁤‏⁠‎⁡⁠⁢⁤⁢‏‏​⁡⁠⁡‌⁤​‎‎⁡⁠⁢‏⁠‎⁡⁠⁣‏⁠‎⁡⁠⁤‏⁠‎⁡⁠⁢⁡‏⁠‎⁡⁠⁢⁢‏‏​⁡⁠⁡‌­
               /^(...)+$/        # ‎⁡Regex that matches a digit or chemical symbol one or more times
        .match(          ):ex    # ‎⁢Get a list of all possible matches of this regex against the input
      +(                     )   # ‎⁣Get the number of elements in that list
 2 min                           # ‎⁤Takes the min of 2 and that number
💎

Created with the help of Luminespire.

Jelly, 124 bytes

“€ṡƥvẏÄhʠ!ịẈ?iḥẋỌ¹'ṅɦçç⁹.Sð$ṚṠȥṢK}/>œ;ỵZƤẓ}:;tÆṾḶj⁶ḄỵḋİʠUḊẈ½^ɲṆßṇµ⁶æḟɦ1¥©ḟþjHṀṪỤƑgạȥḂṾḞƓƑ@Ð⁾æƭVẈṣ’ḃ90Äḃ26ịØaØDW€¤;
ŒṖfƑƇ¢L«2

Try it online!

A set of links that takes a string argument and returns 0 for impossible, 1 for a single valid interpretation and 2 for ambiguous.

Loosely based on @hyper-neutrino’s answer, but mostly rewritten.

JavaScript (ES6), 265 bytes

Saved 6 bytes thanks to @tsh

Expects an array of characters. Returns 0 for unambiguous, 1 for ambiguous, or -1 for impossible.

s=>s.reduce((p,c,i)=>p|=1/c||b?b=0:/[bcfhiknopsuvwy]/.test(c)+(b=/([ace][rsu]|[cgn][ade]|[iz][nr]|a[cglmt]|b[aehikr]|c[fl-o]|d[bsy]|f[elmr]|h[efgos]|kr|l[airuv]|m[cdgnot]|n[bhiop]|o[gs]|p[abdmortu]|r[abe-hnu]|s[bcegimnr]|t[abcehilms]|xe|yb)$/.test(c+s[i+1]))-1,b=0)

Try it online!

How?

The variable \$p\$ holds the final result. The flag \$b\$ is set whenever a 2-character chemical symbol is matched.

For each character \$c\$ at position \$i\$ in the input array:

05AB1E, 117 bytes

Prints -1 for impossible, 0 for unambiguous and 1 for ambiguous.

.œε.•B‚Δ—₅H^ƶƵXJ∍擺l¦¯í-āмIõVÑK:Λ‘(·÷ΓKå<70'V∍∞±ζښ˛¿ĆÅRÙΔu”ípā<À¿ýÌQмÛì‰Óǝ“§KhúγIÑËM`Êιš•#€SASõšøε`ì}˜žhS«såP}O<.±

Try it online!

.œ              # push all partitions of the input
  ε      }      # map over the partitions:
   ...          #   push the table of valid parts (see below)
      s         #   swap to the current partition
       åP       #   test if every part is in the table
          O     # take the sum over all results
           <    # decrease by 1
            .±  # print the sign of this

Compressing the table

.•B...š•                  # alphabet compressed string (contains 26 spaces)
        #                 # split on spaces
         €S               # split each string into a list of chars
           ASõš           # the characters of the alphabet with the empty string prepended
               øε`ì}      # zip alphabet with previous list and prepend matching characters
                    ˜     # flatten the list
                     žhS« # append the digits

Try this part with step-by-step output!

Jelly, 194 bytes

“×ĿcṚ¦mßṛy|3¹,GƊ§ḋCƤṂỴƇƈÇ¡ɱɓkȷ¶ʂạ⁺ịọ9ėżḣ÷8ÆC⁼³°0|KṪƈŀ@:ḤvƥÄƭsɲẸpI0⁷tÞO§ƒ;ḷ8ḟhıA€ḊṪḷ`ɦḊa¥IƭịƤñ¡÷?²ạ©œ5EẏṢɲ⁺ȷɗL4Q¤F⁹~Ṿ⁸ṪṄ|eėgṖ€ṂɠƲ2ʂ⁺ɱḌḳWƘɠṛ;⁵2nȦƝ]ṇUṆ84¥ẸṪḲdþ¹Ẋd©’ṃØẠØD;µe€ØD;ØA¤œṗ
¢Œl⁸ŒṖ¤e€€ȦƇL«2

Try it online!

-2 bytes thanks to caird coinheringaahing via better usage of chaining

Output 2 for ambiguous, 1 for unambiguous, 0 for impossible.

The logic behind this is pretty trivial, I just need to figure out a better way of encoding this periodic table...

“...’ṃØẠØD;µe€ØD;ØA¤œṗ  Helper Link; produce the list of components
“...’                   Compressed Integer
     ṃØẠ                Base-decoded into the upper and lower-case alphabet
        ØD;             Prepend the digits (as strings) as well
           µ            With the list of components (joined on nothing) as the left argument
            e€          Check if each element is in
              ØD;ØA¤    The digits + uppercase alphabet
                    œṗ  And partition the components before those indices

¢Œl⁸ŒṖ¤e€€ȦƇL«2         Main Link
¢Œl                     The components above, lowercased
   ⁸ŒṖ¤                 All ways of partitioning the input
         €              For each partition
        €               For each component
       e                Is it in the list of valid components?
          ȦƇ            Filter to keep partitions where every component was valid
            L           Length; 0 if impossible, 1 if unambiguous, 2+ if ambiguous
             «2         Minimum of the above and 2 (sets ambiguous case to 2 no matter how many occurrences existed)