A list of 174 features found in programming languages.
| title | pseudoExample | yes | no | percentage |
|---|---|---|---|---|
| Comments | # Hello PLDB | 635 | 4 | 99% |
| Line Comments | # Hello PLDB | 537 | 22 | 96% |
| Strings | Hello PLDB | 374 | 2 | 99% |
| Print() Debugging | print "Hello PLDB" | 322 | 1 | 100% |
| MultiLine Comments | /* Hello PLDB */ | 227 | 24 | 90% |
| Integers | 80766866 | 171 | 1 | 99% |
| Floats | 80766866 | 147 | 0 | 100% |
| Booleans | pldb = true | 120 | 8 | 94% |
| Hexadecimals | 80766866 | 110 | 2 | 98% |
| Conditionals | if (isTrue) printPldb() | 78 | 4 | 95% |
| Semantic Indentation | line0 if true line1 print "Hello PLDB" | 72 | 526 | 12% |
| Assignment | name = "PLDB" | 57 | 1 | 98% |
| Octals | 80766866 | 54 | 4 | 93% |
| File Imports | import pldb | 52 | 3 | 95% |
| Functions | function computePLDBRanks() {} | 51 | 2 | 96% |
| While Loops | while (pldb.pop()) loop() | 50 | 4 | 93% |
| Binary Literals | 80766866 | 49 | 1 | 98% |
| Standard Library | print("print is part of stdlib") | 41 | 5 | 89% |
| Operator Overloading | def __add__(): doSomethingDifferent() | 36 | 14 | 72% |
| Classes | class PLDBFile {} | 32 | 6 | 84% |
| Constants | const name = "PLDB" | 30 | 2 | 94% |
| Type Inference | imAString = "pldb" | 28 | 1 | 97% |
| Macros | #define pldbItems 4000 | 28 | 10 | 74% |
| Switch Statements | switch animal: case dog-buy; case cat-sell; | 27 | 2 | 93% |
| Lists | [2, 3, 10] | 25 | 2 | 93% |
| Exceptions | throw new Error("PLDB uh oh") | 24 | 3 | 89% |
| Case Insensitive Identifiers | pLdB = "PLDB" | 24 | 57 | 30% |
| Case Sensitivity | pldb != PLDB | 22 | 9 | 71% |
| Inheritance | class PLDBFile extends File | 22 | 2 | 92% |
| Garbage Collection | var iDontNeedToFreeThis | 22 | 8 | 73% |
| Pointers | int *pldb | 21 | 5 | 81% |
| Directives | use strict; | 21 | 3 | 88% |
| Static Typing | int pldbRank = 100 | 20 | 2 | 91% |
| Access Modifiers | class PLDBFile { public title } | 19 | 3 | 86% |
| Constructors | PLDBFile { constructor() {} } | 17 | 4 | 81% |
| Scientific Notation | 80766866 | 15 | 1 | - |
| Multiple Inheritance | extends parentWhichExtendsSomethingElse | 14 | 6 | 70% |
| Multiline Strings | hello = """Hello\nPLDB""" | 14 | 1 | - |
| Bitwise Operators | 3 == (2 | 1) | 14 | 1 | - |
| Module Pattern | module PLDB {} | 13 | 0 | - |
| Message Passing | get pldb | 13 | 1 | - |
| Pattern Matching | fib 0 = 1; fib 1 = 1 | 12 | 2 | - |
| Structs | struct pldbFile { int rank; char *title; }; | 11 | 0 | - |
| Increment and decrement operators | i++ | 11 | 5 | - |
| Zero-based numbering | firstItem = pldb[0] | 10 | 3 | - |
| Enums | colorsEnum { "red", "white", "blue"} | 10 | 5 | - |
| Single Dispatch | person.run() | 9 | 1 | - |
| Regular Expression Syntax Sugar | /pldb/ | 9 | 6 | - |
| Maps | {name: "PLDB"} | 9 | 0 | - |
| Infix Notation | 1 + 2 | 9 | 0 | - |
| Here Document | `A big multliline text block` | 9 | 1 | - |
| hasForLoops | 9 | 0 | - | |
| Disk Output | write("pldb.csv", "...") | 9 | 4 | - |
| Threads | thread1(); thread2(); | 8 | 1 | - |
| Ternary operators | true ? 1 : 0 | 8 | 8 | - |
| Mixins | extends pldbFile, diskFile | 8 | 1 | - |
| Iterators | for lang in pldb() | 8 | 1 | - |
| Homoiconicity | (list ()) | 8 | 1 | - |
| Function Composition | o = (f, g) => x => f(g(x)) | 8 | 1 | - |
| Type Casting | (float)pldbRank; | 8 | 0 | - |
| Variadic Functions | args.map(doSomething) | 7 | 0 | - |
| Namespaces | namespace PLDB {} | 7 | 2 | - |
| Interfaces | interface PLDBFile | 7 | 1 | - |
| Generics | function identity<T>(arg: T): T | 7 | 1 | - |
| Function Overloading | add(string: str, string2: str) | 7 | 11 | - |
| hasForEachLoops | 7 | 0 | - | |
| Fixed Point Numbers | 80766866 | 7 | 2 | - |
| Expressions | (1 + 2) | 7 | 1 | - |
| Single Pass Compiler | x = 2; print x | 7 | 6 | - |
| Units of Measure | 42cm | 6 | 5 | - |
| Pipes | ls pldb | wc | 6 | 1 | - |
| Manual Memory Management | malloc(4); | 6 | 1 | - |
| Destructuring | {title, rank} = pldbFile | 6 | 1 | - |
| Default Parameters Pattern | say(message = "Hello PLDB") | 6 | 1 | - |
| Async Await | async downloadPldb => await getFiles() | 6 | 3 | - |
| Anonymous Functions | () => printPldb() | 6 | 1 | - |
| Shebang | #! /run | 6 | 0 | - |
| Union Types | any = string | number | 5 | 0 | - |
| Type Classes | 5 | 8 | - | |
| Structural Typing | 5 | 6 | - | |
| Range Operator | 1 ... 10 | 5 | 0 | - |
| Prefix Notation | + 1 2 | 5 | 0 | - |
| Polymorphism | a + "b"; 1 + 2 | 5 | 1 | - |
| Partial Application | add5 = num => addNumbers(10, num) | 5 | 0 | - |
| Operators | 1 + 1 | 5 | 2 | - |
| Null | uhOh = null | 5 | 0 | - |
| Gotos | goto 10 | 5 | 4 | - |
| Doc comments | // param1: A comment about the first param | 5 | 0 | - |
| Dependent types | pldbSortedList // a list where is sorted is true | 5 | 1 | - |
| hasContinue | 5 | 0 | - | |
| hasBreak | 5 | 0 | - | |
| Assert Statements | assert(isTrue) | 5 | 1 | - |
| Unicode Identifers | 未 = 0.00001 | 4 | 2 | - |
| Unary Operators | count++ | 4 | 0 | - |
| Typed Holes | 2 + _ => 2 + [int|float] | 4 | 0 | - |
| Templates | template TCopy(T) {} | 4 | 2 | - |
| Symbol Tables | SymbolName|Type|Scope;bar|function,double|extern | 4 | 0 | - |
| Single-Type Arrays | const pldbRanks: int[] | 4 | 0 | - |
| Sets | {"pldb", "PLDB"} | 4 | 2 | - |
| Postfix Notation | 2 3 4 + 2 - | 4 | 0 | - |
| Named Arguments | 4 | 8 | - | |
| Multiple Dispatch | collide_with(x::Spaceship, y::Spaceship) | 4 | 3 | - |
| hasIfs | 4 | 0 | - | |
| Generators | yield 2 | 4 | 0 | - |
| First-Class Functions | [2.1].map(Math.round) | 4 | 0 | - |
| hasEscapeCharacters | 4 | 1 | - | |
| Dynamic Typing | 4 | 1 | - | |
| Type Parameters | function identity<T>(arg: T): T {return arg} | 3 | 0 | - |
| Type Annotations | score: number | 3 | 0 | - |
| Type Aliases | type Year = number | 3 | 0 | - |
| hasSymbols | 3 | 0 | - | |
| Streams | echo 123 | 123.txt | 3 | 0 | - |
| Static Methods | static downloadPldb() {} | 3 | 0 | - |
| hasSelfOrThisWord | 3 | 0 | - | |
| hasReservedWords | 3 | 2 | - | |
| References | fn(objPointer) | 3 | 0 | - |
| Methods | pldbFile.downloadWebsite() | 3 | 1 | - |
| Magic Getters and Setters | get(name) => obj[name] | 3 | 2 | - |
| Explicit Standard Library | #include <stdio.h> | 3 | 0 | - |
| Lazy Evaluation | print(range(1000000)[2]) | 3 | 0 | - |
| Labels | mainFn: | 3 | 2 | - |
| Implicit Type Casting | console.log("hello " + 2) | 3 | 0 | - |
| hasIfElses | 3 | 0 | - | |
| hasGlobalScope | 3 | 1 | - | |
| hasGradualTypes | a: int # the type is optional | 3 | 0 | - |
| hasFnArguments | 3 | 0 | - | |
| hasDynamicSizedArrays | 3 | 0 | - | |
| Dynamic Properties | pldb.score = 50 | 3 | 2 | - |
| Duck Typing | length() // makes me an iterator | 3 | 2 | - |
| Dispose Blocks Pattern | with pldb: do computeRanks() | 3 | 1 | - |
| Characters | char character = 'P'; | 3 | 0 | - |
| hasBoundedCheckedArrays | 3 | 0 | - | |
| Binary Operators | 1 + 1 | 3 | 0 | - |
| hasArraySlicingSyntax | 3 | 0 | - | |
| canReadCommandLineArgs | 3 | 0 | - | |
| Breakpoints | debugger; | 2 | 0 | - |
| Merges Whitespace | result = 1 + 2 | 2 | 0 | - |
| Letter-first Identifiers | pldb100 = "OK" // 100pldb = "ERROR" | 2 | 0 | - |
| hasVoidFunctions | 2 | 0 | - | |
| Virtual function | virtual FetchPLDBFile(); | 2 | 0 | - |
| Variable Substitution Syntax | name = "PLDB"; print $name | 2 | 10 | - |
| hasUserDefinedOperators | 2 | 2 | - | |
| hasTryCatch | 2 | 2 | - | |
| Traits | use redBorder | 2 | 0 | - |
| hasTimestamps | 2 | 0 | - | |
| hasStringConcatOperator | 2 | 0 | - | |
| Statements | print "Hello PLDB" | 2 | 1 | - |
| hasStatementTerminatorCharacter | 2 | 0 | - | |
| Source Maps | {file: 'pldb.min.js',sources: ['pldb.js'], mappings: 'CAAC,IAAI,IAAM'} | 2 | 0 | - |
| Runtime Guards | f x | x > 0 = 1 | otherwise = 0 | 2 | 0 | - |
| hasRequiredMainFunction | 2 | 1 | - | |
| Method Chaining | pldbFile.toString().length | 2 | 0 | - |
| hasMemberVariables | 2 | 0 | - | |
| Map Functions | pldbFiles.map(downloadFilesFn) | 2 | 0 | - |
| Implicit Arguments | shout(implicit message: string) | 2 | 0 | - |
| hasExports | 2 | 0 | - | |
| Decimals | 0.80766866 | 2 | 0 | - |
| hasBuiltInRegex | 2 | 2 | - | |
| Algebraic Data Type | garageContents = empty | vehicle | 2 | 0 | - |
| Zippers | pldbCursor.moveLeft() | 1 | 0 | - |
| hasValueReturnedFunctions | 1 | 0 | - | |
| Triples | Javascript isListedIn PLDB | 1 | 0 | - |
| S-Expressions | (+ 1 1) | 1 | 3 | - |
| Refinement Types | evenInt where int % 2 = 0 | 1 | 0 | - |
| Processor Registers | eax 2 | 1 | 1 | - |
| Pairs | (pl . db) | 1 | 0 | - |
| Monad | g >>= f | 1 | 0 | - |
| hasMethodOverloading | 1 | 1 | - | |
| hasIds | 1 | 0 | - | |
| Decorators | @deprecated | 1 | 0 | - |
| Clobs | class PLDBFile {} | 1 | 0 | - |
| hasBlobs | 1 | 1 | - | |
| Abstract Types | abstract class PLDBFile {} | 1 | 2 | - |
| canUseQuestionMarksAsPartOfIdentifier | 1 | 1 | - |