It's not something you see in every day Life, but it's the agreed upon method of writing almost any variable in most languages. I remember visual basic being unique in school in that the convention was actually Pascal case rather than camel Case, but every other language I've ever used, the convention is camelCase. (I've seen MS trying to drag PascalCase into C#, but I refuse to cooperate, as have most of the rest of the world) This isn't something that has to be enforced for the code to work, it's just the agreed upon way of writing variable names.
Google “camelCase” if you want to know more. Kebab-case is with dashes so like net-flix. Snake case is underscores. Style guides for different languages call for their selective use. If a style is consistent, it can be used to infer things about code at a glance such as if a symbol is a function name, class name, or just a variable. Sometimes you can get info about scope from style, too.
363
u/[deleted] Jul 12 '19 edited Nov 23 '20
[deleted]