anndy smaals

anndy smaals

  • 1.9k
  • 24
  • 1.8k

loop that identify values

Dec 15 2018 2:25 PM
a for loop that identifies all the values between the lowerBounds and the upperBounds inclusive that are evenly divisible by 5 (e.g. 5, 10, 15)
and adds them to the variable sum.
 
using System;

namespace HelloWorld
{
class Program
{
static void Main(string[] args)
{
int lowerBounds = 1;
int upperBounds = 1000;
int sum = 0;


Console.WriteLine(sum);
}
}

Brought to you by:

Answers (1)