Any Java Experts? More Help! - Fantasy Baseball Cafe 2014 Fantasy Baseball Cafe
100% Deposit Bonus for Cafe Members!

Return to General Talk

Any Java Experts? More Help!

Moderator: Baseball Moderators

Re: Any Java Experts? More Help!

Postby Tavish » Thu Jan 28, 2010 12:28 am

You are skipping the first even term in your loop. Your first evaluation is 3+2.

Bury me a Royal.
Mod in Retirement
Mod in Retirement

User avatar
CafeholicFantasy ExpertCafe WriterCafe RankerMock(ing) DrafterEagle EyeCafe SpotterWeb Supporter
Posts: 11067
(Past Year: 26)
Joined: 3 May 2004
Home Cafe: Baseball

Re: Any Java Experts? More Help!

Postby sox 06 » Thu Jan 28, 2010 12:05 pm

Tavish wrote:You are skipping the first even term in your loop. Your first evaluation is 3+2.

Ah there you go! I feel like an idiot sometimes with this Java stuff !+) But I'm getting better :-D

Alright, another question. I've gone on Google to look for this, but I've been a bit confused about what I've read. How do you add a string of numbers together? I have the code written for 2 raised to the 1000th power, but now I need to add each digit in that answer and print out the sum. Do I need to use something like a toString in the BigInteger class? Here is what I have so far:

sox 06
General Manager
General Manager

User avatar
CafeholicEagle Eye
Posts: 4425
Joined: 22 Apr 2006
Home Cafe: Baseball


Return to General Talk

Who is online

Users browsing this forum: No registered users and 6 guests

Forums Articles & Tips Sleepers Rankings Leagues

Today's Games
Saturday, Aug. 23
(All times are EST, weather icons show forecast for game time)

Chi White Sox at NY Yankees
(1:05 pm)
Tampa Bay at Toronto
(1:07 pm)
Detroit at Minnesota
(1:10 pm)
Seattle at Boston
(1:35 pm)
Baltimore at Chi Cubs
(2:20 pm)
San Francisco at Washington
(4:05 pm)
Houston at Cleveland
(7:05 pm)
St. Louis at Philadelphia
(7:05 pm)
Pittsburgh at Milwaukee
(7:10 pm)
Atlanta at Cincinnati
(7:10 pm)
San Diego at Arizona
(8:10 pm)
Miami at Colorado
(8:10 pm)
Detroit at Minnesota
(8:10 pm)
Kansas City at Texas
(8:25 pm)
LA Angels at Oakland
(9:05 pm)
NY Mets at LA Dodgers
(9:10 pm)

  • Fantasy Baseball
  • Article Submissions
  • Privacy Statement
  • Site Survey 
  • Contact