Challenge: Array of Integers

Sumit Rawal answered on May 23, 2023 Popularity 1/10 Helpfulness 1/10

Contents


More Related Answers

  • Challenge: Array of Squares

  • Challenge: Array of Integers

    0

    Problem Statement

    Input

    Output

    Sample Input

    Sample Output

    Test Yourself

    Problem Statement

    You have to create and populate an array of integers within a given range. Multiply each element in the range with 3. The elements of the final array should only contain even numbers.

    Input

    The input is the lower bound minRange and upper bound maxRange of the range which you will use to populate the array.

    minRange and maxRange have already been declared for you.

    Output

    The output will be the populated finalArray.

    Sample Input

    (1, 5)

    Sample Output

    Array(6, 12)

    Test Yourself

    Write your code in the given area. Try the exercise by yourself first, but if you get stuck, the solution has been provided. Good luck 

    Popularity 1/10 Helpfulness 1/10 Language scala
    Source: Grepper
    Tags: scala
    Link to this answer
    Share Copy Link
    Contributed on May 23 2023
    Sumit Rawal
    0 Answers  Avg Quality 2/10


    X

    Continue with Google

    By continuing, I agree that I have read and agree to Greppers's Terms of Service and Privacy Policy.
    X
    Grepper Account Login Required

    Oops, You will need to install Grepper and log-in to perform this action.