Languages Features Calendar CSV Lists Blog About Sponsor Add Language
GitHub icon



Conditionals are a feature.

In computer science, conditional statements, conditional expressions and conditional constructs are features of a programming language, which perform different computations or actions depending on whether a programmer-specified boolean condition evaluates to true or false.

Languages without Conditionals include HTML, XML, JSON

Languages with Conditionals include Java, JavaScript, C, Python, C++, PHP, Perl, C#, Ruby, R, Go, Swift, Scala, Rust, Haskell, Pascal, Ada, Lua, Kotlin, PowerShell, Elixir, Erlang, Objective-C, Julia, Dart, Scheme, Reason, Bash, Crystal, F#, Verilog, Solidity, OCaml, CoffeeScript, Groovy, VHDL, Chapel, ABAP, Dylan, AutoIt, X10, Pug, F*, Clean, SystemVerilog, Opa, HCL, ATS, Bicep, Twig, Maxima, Koka, HOPE, Felix, Slope, Angelscript, Jule, Apex, Flow9, Q#, PowerQuery M, Ligo, Sophia, nimrod

Example from JavaScript:
if (true) console.log("hi!")
Example from Python:
if True: print("Hello world")
Example from Elixir:
if true do IO.puts("Hello world") end
Example from Slope:
(if positive? 1 -1)
classes-feature.html 路 conditionals-feature.html 路 constants-feature.html

View source

PLDB - Build the next great programming language 路 v2022 Day 33 Docs Build Acknowledgements Traffic Today Traffic Trends Mirrors GitHub