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

 

jebbert@volusia.k12.fl.us > countEvenDigits
prev  |  next  |  chance

Write a method that uses "/" and "%" and does NOT use strings. This method will return the number of even DIGITS in a positive integer parameter. Look at the test data for examples.


countEvenDigits(2412) → 3
countEvenDigits(7953) → 0
countEvenDigits(864) → 3

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

public int countEvenDigits(int num) { }

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: 290

Copyright Nick Parlante 2017 - privacy