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

 

borlaj@portlandschools.org > findEvens
prev  |  next  |  chance

create function findEvens that will take in two numbers a,b and find how many nubmers between them are even, so findEvens (6,10) would return 3 (because 6,8,10 are even)


findEvens(6, 10) → 3
findEvens(12, 19) → 4
findEvens(20, 104) → 43

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

public int findEvens(int a, int b){ }

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

Copyright Nick Parlante 2017 - privacy