id/email
password
forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice

 

tlsmith2@wsfcs.k12.nc.us > arrayLowestEvenNumber
prev  |  next  |  chance

Return the lowest even number from an array of positive integers. If there are no even numbers, return -1.


arrayLowestEvenNumber([1, 4, 3, 2]) → 2
arrayLowestEvenNumber([8, 0, 10]) → 0
arrayLowestEvenNumber([5, 1, 13, 51]) → -1

...Save, Compile, Run (ctrl-enter)

public int arrayLowestEvenNumber(int[] nums) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

Progress graphs:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Java Help

Misc Code Practice

Difficulty: 10 Post-solution available

Copyright Nick Parlante 2017 - privacy