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

 

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

Write a method that returns the sum of the prime factors of the input parameter 'num' (remember that 1 is not a prime number). The parameter 'num' will be a positive integer greater than 1.


mar11_2016_SLHL_sumFactors(2) → 2
mar11_2016_SLHL_sumFactors(5) → 5
mar11_2016_SLHL_sumFactors(7) → 7

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

public int mar11_2016_SLHL_sumFactors(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: 230

Copyright Nick Parlante 2017 - privacy