× Didn't find what you were looking for? Ask a question
Top Posters
Since Sunday
s
3
v
3
p
3
m
2
s
2
d
2
N
2
d
2
e
2
s
2
s
2
e
2
New Topic  
DePeet DePeet
wrote...
Posts: 338
Rep: 0 0
6 years ago
Rewrite the following iterative method as a recursive method that computes the same thing.  Note:  your recursive method will require an extra parameter.
   public int iterative1(int x)
   {
      int count = 0, factor = 2;
      while (factor < x)
      {
         if (x % factor == 0) count++;
         factor++;
      }
      return count;
   }
Read 72 times
1 Reply
Replies
Answer verified by a subject expert
StingerStinger
wrote...
Posts: 310
Rep: 4 0
6 years ago
Sign in or Sign up in seconds to unlock everything for free
1

Related Topics

DePeet Author
wrote...

6 years ago
This site is awesome
wrote...

Yesterday
Just got PERFECT on my quiz
wrote...

2 hours ago
Smart ... Thanks!
New Topic      
Explore
Post your homework questions and get free online help from our incredible volunteers
  1070 People Browsing
Related Images
  
 14285
  
 3574
  
 143
Your Opinion
What's your favorite math subject?
Votes: 559