The no of electrons present in the valence shell of an atom determines whether it’s a metal, non-metal or metalloid. If an element has 1,2 or 3 electrons in its valence shell it is considered as a metal, if it has 5,6 or 7 electrons it is considered as a non-metal and if it has 4 electrons in its valence shell then it is considered as a metalloid. Carbon has 4 electrons in its valence shell which makes it a metalloid but commonly it is considered as a non-metal. Carbon shows more characteristics of a non-metal.