The following explanation is from DR. Ray's Long List of Editorial Pet Peeves:
The abbreviation “e.g.” is from the Latin meaning exempli gratia, or “for example.” This abbreviation should only be used in a parenthetical comment. There should be a period after both “e” and “g” since it is an abbreviation of two Latin words.
EX: Brittle materials (e.g., glass) fracture without experiencing strain hardening
EX is short for the word example. I've also seen it written Ex and ex. Use it, as the author above has, to mark a specific example.
The primary difference is that "e.x." is incorrect.
People who use "e.x." as a short form for "for example" are simply ill-informed or uneducated. (I'd suggest possibly also lazy, except that it takes just as long to type e.g. as it does e.x........so, that can't be it!)
If you have a question about the English language and would like to ask one of our many English teachers and language experts, please click the button below to let us know: