0

I'm doing some work in C++ on Fibonacci numbers which quickly grow out of bounds and I can't use them anymore. I need big integer functionality, which is not built in to C++ and int primitives aren't good enough.

I've found a few libraries that work with big ints, like GMP and CLN (the C++ Library for Numbers) but the installation instructions don't make sense to me.

How would I install GMP to work on windows 10? I use Codeblocks to write and build and run everything and my compiler is MinGW which is in my C:\ directory. How do I add GMP so that I can #include the library in a codeblocks C++ project?

I am a moron, and I require step by step instructions down to "download the file in this directory, move the .lib file into this directory, etc". I am not capable of understanding the given instructions for installation on the GMP website.

moreQthanAs
  • 1
  • 1
  • 4
  • Unrelated: You almost never want to *move the .lib file into this directory*. Prefer to leave the lib file where it is and instead add the path to the library to the linker's list of library paths. See [How do I link to a library with Code::Blocks?](https://stackoverflow.com/questions/5862757/how-do-i-link-to-a-library-with-codeblocks) for details (and what should answer about half of your question). – user4581301 Dec 10 '19 at 22:17
  • The instructions for directing Code::Blocks to the location of include files is similar. Mouse around the tabs in the Project build options window and you'll see where to add them. – user4581301 Dec 10 '19 at 22:19
  • A comment on your question: You would be better served asking questions about how to interpret the GMP instructions. You will find that A) instructions rarely get much better and B) they usually make perfect sense when you know the lingo. It's much better to learn the lingo than always be slave to third party tutorial makers. – user4581301 Dec 10 '19 at 22:23

0 Answers0