function multiply(a, b = 1) {
return a * b;
}
public void ExampleMethod(string optionalstr = "default string") {}
def multiply(a, b \\ 1) do
a * b
end
fn void test(int x = 10) { ... }
function Find (|string| pattern, |int| pos=0, |int|)
Languages with Default Parameters Pattern include JavaScript, C#, Elixir, Chapel, C3, Speedie
Languages without Default Parameters Pattern include Lil
View all concepts with or missing a hasDefaultParameters measurement
Read more about Default Parameters Pattern on the web: 1.