How to differentiate class and id while applying CSS?

How to differentiate class and id while applying CSS?

  1. An ID selector can be used to identify one element, whereas a Class selector can be used to identify more than one.
  2. A class selector is a name preceded by a full stop (“.”) whereas an ID selector is a name preceded by a hash character (“#”).