I constantly forget which is Camel case and which is Pascal case. So I thought that maybe a little history will help. Where do the names of these conventions come from? Is t
I could be wrong. PEP 8, for those writing in python, suggests otherwise.
i.e. in python => CamelCase
https://www.python.org/dev/peps/pep-0008/
Pascal Case: in Pascal case every word of each letter should be capital like MossawarHussain
Camel case: As the name show it follow the camel structure of word like mossawarHussain
Difference:
Pascal is a subset of Camel case. The first letter of Pascal is capital and first letter of the camel is small that is the major difference between these two cases.
In camel case first letter of first word lower case, and first letter of every word, after that should be Upper Case.
Ex: userName userFullName
In pascal case first letter of every word should be upper case.
Ex: UserName UserFullName
For anyone looking, here's a Python module that'll do either case: to-camel-case
pip install to-camel-case
import to_camel_case
to_camel_case('snake_case') # snakeCase
to_camel_case('snake_case', pascal=True) # SnakeCase
Full disclosure: I'm the author
camel case - first letter of first word lower case, and first letter of every word, after that should be Upper Case.
Examples:
pascal case - first letter of every word should be upper case.
Examples:
To remember camel case you have to think about the shape of the capital letters. They are like the humps of a camel as you can see in this image.
Pascal Casing - capitalizes each word:
ThisShouldBePascalCase
Camel Casing - is similiar to pascal case but the first word is not capitalized:
thisShouldBeCamelCase
You can read some history here
UPDATE: Change the camel case image after reading the comments.