Some programming languages, like Pascal, use the ASCII apostrophe to delimit string literals. In many languages, including JavaScript, ECMAScript, and Python, either the apostrophe or the double quote may be used, allowing string literals to contain the other character (but not to contain both without using an escape character), e.g. foo='He said "Bar!"';. Strings delimited with apostrophes are often called single quoted. Some languages, such as Perl, PHP, and many shell languages, treat single quoted strings as "raw" strings, while double quoted strings have expressions (such as "$variable") replaced with their values when interpreted.
The C programming language (and many derived languages like C++, Java, C#, and Scala) uses apostrophes to delimit a character literal. In these languages a character is a different object than a one-letter string.
In C++, since C++14, apostrophes can be included as optional digit separators in numeric literals.
In Visual Basic (and earlier Microsoft BASIC dialects such as QuickBASIC) an apostrophe is used to denote the start of a comment.
In the Lisp family of programming languages, an apostrophe is shorthand for the quote operator.
In Rust, in addition to being used to delimit a character literal, an apostrophe can start an explicit lifetime.