PLDB
Languages Features Creators Calendar CSV Resources Blog About Donate Add Language
GitHub icon

Conditionals

< >
if (true) console.log("hi!")
Example from Python, Cython:
if True: print("Hello world")
Example from Elixir:
if true do IO.puts("Hello world") end
Example from Pug:
- var user = {description: 'foo bar baz'} - var authorised = false #user if user.description h2.green Description p.description= user.description else if authorised h2.blue Description p.description. User has no description, why not add one... else h2.red Description p.description User has no description
Example from Slope:
(if positive? 1 -1)
Example from Jule:
if BOOLEAN_EXPRESSION { outln(""Condition is true) }
Example from BALGOL:
EITHER IF A > B$ FWD = 1$ OTHERWISE$ FWD = 0$

Languages with Conditionals include Java, JavaScript, C, Python, C++, PHP, Perl, C#, Ruby, R, Go, Scala, Swift, Ada, Rust, Kotlin, PowerShell, Pascal, Haskell, Lua, TypeScript, Bash, Objective-C, Elixir, Erlang, Scheme, Julia, Dart, Verilog, Solidity, Reason, Crystal, CoffeeScript, F#, OCaml, Groovy, VHDL, Chapel, Pug, ABAP, Dylan, AutoIt, X10, Clean, F*, SystemVerilog, Opa, Cython, HCL, ATS, C3, Bicep, Twig, Maxima, janet, Koka, HOPE, progsbase, Felix, Slope, Jule, Angelscript, Pizza, Apex, C2, Flow9, Q#, PowerQuery M, Ligo, JS++, BALGOL, Sophia, nimrod, fp, Deesel, Tick C, cooC, Real-Time Concurrent C, ADLIB, Static Typescript, Extended Pascal

Languages without Conditionals include HTML, XML, JSON, JSON5, Ion, JSONiq, JSON with Comments, Superjson, Hocon, Jsonnet

Read more about Conditionals on the web: 1.

HTML of this page generated by Features.ts

hasComments.html 路 hasConditionals.html 路 hasConstants.html

View source

PLDB - Build the next great programming language Search v2023 Day 157 Docs Acknowledgements Traffic Today Traffic Trends Mirrors GitHub feedback@pldb.com