Skip to content

The array of numbers stored in arr and from the position in the array where a 1 is, return the number of spaces either left or right.

Notifications You must be signed in to change notification settings

DanNY0805/ArrayChallengeNV

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

ArratChallengeNV

The array of numbers stored in arr and from the position in the array where a 1 is, return the number of spaces either left or right.

Have the function ArrayChallenge(arr) take the array of numbers stored in arr and from the position in the array where a 1 is, return the number of spaces either left or right you must move to reach an enemy which is represented by 2. The array will contain any number of 0's and 2's, but only a single 1. It may not contain any 2's at all as well , where in that case the program should return 0, in java

About

The array of numbers stored in arr and from the position in the array where a 1 is, return the number of spaces either left or right.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages