snake case

English

Examples
  • number_of_arguments
  • find_new_objects

Etymology

Coined in 2004 by Ruby programmer Gavin Kistner, from its resemblance to the long body of a snake, and by analogy with other naming schemes based on lower- and upper-case letters.

Noun

snake case or snake_case (uncountable)

  1. (programming) The practice of writing identifiers using underscores to separate words.
    • 2018, Camille McCue; Sarah Guthals, Helping Kids with Coding For Dummies®, John Wiley & Sons, Inc., →ISBN, page 130:
      Some evidence shows that coders are better able to read code (their code and code written by others) when using snake_case, not camelCase naming.
    • 2020, Jeanne Boyarsky; Scott Selikoff, OCP Oracle Certified Professional Java SE 11 Programmer I: Study Guide, Exam 1Z0-815, John Wiley & Sons, Inc., →ISBN, page 49:
      While both camelCase and snake_case are perfectly valid syntax in Java, the development community functions better when everyone adopts the same style convention.
    • 2020, Titus Winters; Tom Manshreck; Hyrum Wright, Software Engineering at Google: Lessons Learned from Programming Over Time, O’Reilly Media, Inc., →ISBN:
      We were incorporating third-party Python libraries for some of our projects, leading to a mix within our codebase of our own CamelCase format with the externally preferred snake_case style.

Coordinate terms

Derived terms

Further reading

This article is issued from Wiktionary. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.