integer limits and 1 minute rule

Announcements, comments, ideas, feedback, and "How do I... ?" questions
Post Reply
karenhunt6116
Posts: 18
Joined: Tue Sep 29, 2009 3:43 pm
Location: Detroit, MI

integer limits and 1 minute rule

Post by karenhunt6116 » Mon Jun 07, 2010 5:40 pm

Should my program still solve in 1 minute when the problem involves integers greater than the limit of my programming language?

User avatar
stijn263
Posts: 1505
Joined: Sat Sep 15, 2007 10:57 pm
Location: Netherlands

Re: integer limits and 1 minute rule

Post by stijn263 » Mon Jun 07, 2010 5:57 pm

Almost all problems are designed such that they can be solved with normal 64 bit integers. What programming language are you using and which problem are you trying to solve?

karenhunt6116
Posts: 18
Joined: Tue Sep 29, 2009 3:43 pm
Location: Detroit, MI

Re: integer limits and 1 minute rule

Post by karenhunt6116 » Mon Jun 07, 2010 7:12 pm

Thank you for your response.

I am using VBA for excel. I am trying to solve problem 290.

User avatar
stijn263
Posts: 1505
Joined: Sat Sep 15, 2007 10:57 pm
Location: Netherlands

Re: integer limits and 1 minute rule

Post by stijn263 » Tue Jun 08, 2010 7:32 am

I don't know whether excel supports 64 bit, but in a language like that it's perfectly fine to follow the 15 minute rule :-)

karenhunt6116
Posts: 18
Joined: Tue Sep 29, 2009 3:43 pm
Location: Detroit, MI

Re: integer limits and 1 minute rule

Post by karenhunt6116 » Wed Jun 09, 2010 7:15 pm

Thanks again.

I just checked with the IT Manager. It is most likely my computer is a 32-bit integer machine.

quilan
Posts: 182
Joined: Fri Aug 03, 2007 10:08 pm

Re: integer limits and 1 minute rule

Post by quilan » Thu Jun 10, 2010 1:30 am

karenhunt6116 wrote:Thanks again.

I just checked with the IT Manager. It is most likely my computer is a 32-bit integer machine.
It's not that; many/most languages feature 64-bit data types even on 32-bit integer machines. VBA on the other hand, only really has the Currency type that's 64-bit and the Decimal type that's 96-bit. Problem is that manipulating Currency/Decimal objects is a wonky affair at best. I really loathe saying this, but if you're going to tackle a lot of the more recent problems (which usually require 64-bit math), you'd really really really really be doing yourself a favor by using a programming language designed for complicated processing (eg. Python, C++ for easy learning, something like ML or Haskell if you want to challenge yourself & learn new paradigms).

My 2c.
ex ~100%'er... until the gf came along.
Image

Post Reply