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

 

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

Write a method that returns the product of all the digits of a non-negative integer parameter 'num'. For example, if 'num' is 516, return 30 since 5*1*6=30. Look at the test data for further examples.


quiz2023_02_28_APP1SLHL_digitProduct(7812) → 112
quiz2023_02_28_APP1SLHL_digitProduct(1234) → 24
quiz2023_02_28_APP1SLHL_digitProduct(7845) → 1120

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

public int quiz2023_02_28_APP1SLHL_digitProduct(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: 220

Copyright Nick Parlante 2017 - privacy