Java Beginner: Help with methods and returning values (hailstone program)
Hello everyone, I am rather new to java and I need some help with understand methods.
I can figure out how to call the integers and I returns from each method. I have attached my .java file and I appreciate everyones help.
I need to call int length, int start and int max. Each integer is returned from its own method.
I am unsure how to call the integers to output them.
Re: Java Beginner: Help with methods and returning values (hailstone program)
finally figured it out.
all i needed was
int start = getStartingValue(in);
int max = computeMax(start);
int length = computeLength(start);
outputResults(start, length, max);