How do you classify a compound as a weak electrolyte, strong electrolyte, or non electrolyte, simply by looking at the formula?
Electrolytes are compounds that dissolve as ions in a polar solvent, particularly water. Strong electrolytes completely ionize in water. Weak electrolytes partially ionize in water, and non electrolytes do not form ions in water at all.
The best way to look at a chemical and determine if it is an electrolyte or not is to recognize if it is a classic inorganic salt. A classic inorganic salt is composed of cations and anions. They are often composed of a metal making an ionic bond with a non-metal. That is to say, an element on the left of the periodic table and an element on the right of the periodic table. An example is sodium chloride, NaCl. This is a salt composed of an ionic bond, so it will ionize completely in water and is a strong electrolyte. Memorizing the most common monoatomic and polyatomic cations and anions will serve you well here.
If a chemical is composed of several carbon atoms like glucose (C6H12O6), then the compound may dissolve in water but it will not ionize at all, thus making it a non electrolyte. Weak electrolytes are a bit tougher. Many weak electrolytes contain carboxylic acids (COOH). This is a group that is weakly acidic, so it partially ionizes in water and is a weak electrolyte.