The list of the abbreviations you can find and use in software environments.
global
• understood by everyonesignificant
• seen for the first time you still know what it meansabsolute
• not related to the contextshort
• taking out one letter is not an abbreviation
Giving good names to variables, functions, classes, files etc. can be difficult. Long names are always clear, but take time to read, take up space and are hard to remember. Choosing a shorter form is better.
If you use the abbreviations below, your naming will become more coherent, logical and understandable to other programmers (even newbies).
Abbreviations are in key–value format. Multiple choices are sorted from most to least used. Colored circles signify the degree of recommendation:
- 🟢 Recommended
- 🟡 Context-sensitive
- 🔴 Not recommended
Unrecommended ones can still be considered. The most important thing is to remain consistent in your code.
- 🔴 2 • to
- 🟢 abbr • abbreviation
- 🟢 abs • absolute number
- 🔴 act • action / active / actual
- 🟢 addr • address
- 🟡 alloc • allocate {memory}
- 🟢 alt • alternative / alternate
- 🟢 app • application
- 🟡 arg • argument {memory}
- 🟢 arr • array
- 🟢 async • asynchronous
- 🟢 attr • attribute
- 🟢 auth • authentication / authenticate
- 🟢 avg • average
- 🟡 bat • battery {power}
- 🟢 bg • background
- 🟢 bin • binary
- 🟡 bl • breakline {encoding}
- 🟢 bool • boolean
- 🔴 brk • break
- 🟢 btn • button
- 🟢 buf • buffer
- 🟢 calc • calculate / calculator
- 🟢 cb • callback
- 🟢 cert • certificate
- 🟡 ch • channel {connection}
- 🟢 chk • check
- 🟢 char • character
- 🟡 circ • circle {shape}
- 🟢 clr • clear
- 🟢 cmd • command
- 🟡 cmp • compare {conditional operator}
- 🟢 cnt • counter
- 🟢 concat • concatenate
- 🟢 conf / config • configuration
- 🟢 conn • connection {connection}
- 🟢 cont • continue
- 🟢 conv • conversation
- 🟢 col • column
- 🟢 coll • collection
- 🔴 com • commercial / common / communication
- 🟢 coord • coordinate
- 🟢 cos • cosine
- 🟢 cot • cotangent
- 🟡 csum • checksum {operation}
- 🟢 ctrl • control
- 🟢 ctx • context
- 🟢 cur / curr • current
- 🔴 cpy • copy
- 🟢 db • database
- 🟢 dbg • debug
- 🟢 dec • decimal / decrease
- 🟢 def • default / define
- 🟢 del • delete
- 🟢 dest • destination
- 🟢 dev • development / device / developer
- 🟡 diff • difference {operation}
- 🟢 dir • directory / direction
- 🟢 dis • disable
- 🟢 disp • display
- 🟢 doc • document
- 🟢 drv • driver
- 🟢 dsc • descriptor
- 🟡 dt • delta time {calculation}
- 🟢 dyn • dynamic
- 🟢 e • event
- 🟢 e.g. • example
- 🟢 en • enable
- 🟢 env • environment
- 🟡 eq • equal {binary operation}
- 🟢 err • error
- 🟢 exe • executable
- 🟢 expr • expression
- 🟢 ext • extension
- 🟢 etc • etcetera
- 🟢 f / func • function
- 🟢 fac • factory
- 🟢 fd • file descriptor
- 🟢 fig • figure
- 🟢 fmt • format
- 🟢 fp • function pointer
- 🟡 ge • greater or equal {binary operation}
- 🟢 gen • generate
- 🟡 gt • greater than {binary operation}
- 🟡 h • height {shape}
- 🟢 hex • hexadecimal
- 🔴 hdr • header
- 🟡 hor • horizontal {shape}
- 🟡 hw • hardware {computer science}
- 🟢 id • identifier
- 🟢 idx • index
- 🟢 iface • interface
- 🟢 img • image
- 🟢 in • input
- 🟢 inc • include / increase
- 🟢 info • information
- 🟢 init • initialize
- 🟢 ins • insert
- 🟢 intf • interface
- 🟢 int • integer
- 🟢 iter • iterator
- 🟢 js • javascript
- 🟡 key • object key {only with val}
- 🟢 lang • language
- 🟢 lat • latitude
- 🟢 lib • library
- 🟡 le • less or equal {binary operator}
- 🟢 len • length
- 🟢 ll • linked list
- 🟢 lng • longitude
- 🟡 lt • less than {binary operators}
- 🟢 max • maximum
- 🟢 mcu • microcontroller
- 🟢 mem • memory
- 🟡 meta • metadata {data science}
- 🟢 mid • middle
- 🟢 min • minimum
- 🟢 misc • miscellaneous
- 🟢 mng • manager
- 🟢 mod • modulo
- 🟢 msg • message
- 🟡 mut • mutable {variables}
- 🔴 n • no {only with yes}
- 🟢 nav • navigation
- 🟡 ne • not equal {binary operator}
- 🟢 net • network
- 🟡 nl • newline {endcoding}
- 🟢 num • number
- 🟢 obj • object
- 🔴 ord • order {data science}
- 🟡 op • operation {binary operation}
- 🟢 opt • option / optional
- 🟢 os • operating system
- 🟢 out • output
- 🟡 p • pointer {memory}
- 🟢 param • parameter
- 🟢 perf • performance
- 🟢 pic • picture
- 🟢 pos • position
- 🟢 pr • pull request
- 🟢 pred • prediction
- 🟢 pref • preference
- 🟢 prev • previous
- 🟢 priv • private
- 🟡 proc • process {thread}
- 🟢 prod • production
- 🟢 prof • profiler
- 🟢 ptr • pointer
- 🟢 pub • public
- 🟡 pwr • power {energy}
- 🟢 px • pixel
- 🟢 q / qry • query
- 🟡 r • radius {circle / shape}
- 🟢 rand • random
- 🟢 rec • record
- 🟡 rect • rectangle {shape}
- 🟢 recv • receive
- 🟢 ref • reference
- 🟢 regex / rgx • regular expression
- 🟢 rem • remove
- 🟢 repo • repository
- 🟢 req • required / requested
- 🟢 res • response / result
- 🟢 ret • return
- 🟢 rev • revision
- 🟢 rng • range
- 🟡 s • signed as prefix {modifier}
- 🟡 sem • semaphore {conditional operator}
- 🟢 sel • selected / selection
- 🟢 sin • sine
- 🟢 seq • sequence
- 🟢 sqrt • square root
- 🟢 src • source
- 🟡 sw • software {computer science}
- 🟢 stat • statistic
- 🟢 std • standard
- 🟢 str • string
- 🟢 sum • addition
- 🟢 sync • synchronize
- 🟡 t • time / type (e.g. uint8_t) {type modifier}
- 🟢 temp • temperature
- 🟢 temp / tmp • temporary
- 🔴 tgl • toggle
- 🟢 tmr • timer
- 🟢 ts • timestamp
- 🔴 txt • text
- 🟡 u • user {URLs}
- 🔴 usr • user
- 🟢 v • value {only with k}
- 🟡 v • vector / version
- 🟢 val • value
- 🟢 var • variable
- 🟢 ver • version / vertical
- 🟡 w • width {shape}
- 🟢 win • window
- 🟡 ws • white space {encoding}
- 🟡 y • yes {only with n}
- 🟡 $... • node ($btn) {jQuery selector / DOM}