zaagan
12/29/2019 - 11:28 AM

Ruby Basic - While Loop

Ruby Basic - While Loop

x = 10
while x >= 0
  p x
  x = x - 1
end
# Output >
# 10
# ...
# 0