Skip to content

Commit 695ed45

Browse files
committed
Setting up default value for currWheat if total is not provided
1 parent aa734cc commit 695ed45

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

pigeons-challenge/pigeons.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
function feeding(totalWheat){
1+
function feeding(totalWheat = 0){
22
let pigeonsTotal = 0;
33
let nextPigeonGroup = 1;
44
let currWheat = totalWheat;

0 commit comments

Comments
 (0)