Write a for loop that prints in ascending order all the positive multiples of 5 that are less than 175, separated by spaces.

LANGUAGE: C++

CHALLENGE:

Write a for loop that prints in ascending order all the positive multiples of 5 that are less than 175, separated by spaces.

SOLUTION:

The Bad News: The content you are trying to access is only available to members.

The Good News: You too can be a member, simply Click Here.

Already a member?

Posted in ,

2 Comments

  1. Malcolm A. Morgan on February 19, 2016 at 6:18 am

    THIS IS THE CODE FOR C:

    int i;

    for (i=1; i<175; i++){
    if ((i % 5) == 0){
    printf(" %d", i);
    }
    }

  2. William Rodgers on December 1, 2016 at 7:18 pm

    int i;
    for ( i = 5; i<175; i+=5)
    {
    System.out.print(i + " ");
    }

Leave a Comment

You must be logged in to post a comment.