Modulo Operation with big numbers

Write here if you have problems with your C source code

Moderator: Board moderators

Post Reply
r.z.
Learning poster
Posts: 56
Joined: Thu Jun 05, 2003 1:57 pm

Modulo Operation with big numbers

Post by r.z. » Tue Jul 01, 2003 7:06 pm

I use mod operation to deal with big numbers (10^101) but the result is not correct....(I used fmod)

can someone help me?

zsepi
Learning poster
Posts: 51
Joined: Thu Sep 26, 2002 7:43 pm
Location: Easton, PA, USA

Post by zsepi » Tue Jul 01, 2003 10:57 pm

rz,

as far as I know fmod takes double parameters - and I am pretty positive that numbers in the range of 10^101 are not really fitting in a double.... plus I believe that this problem wasn't designed to be solved by standard library fucntions. There are several problems on the acm site, which are related to big numbers, and they are all fairly easy, once you get the hold fo it - spend some time developing your bigNumber library, and just use them :) if you search this forum, i recall there was a _huge_ C++ library
Dealing with failure is easy: Work hard to improve.
Success is also easy to handle: You've solved the wrong problem. Work hard to improve.

User avatar
Moni
Experienced poster
Posts: 202
Joined: Fri Mar 22, 2002 2:00 am
Location: Chittagong. CSE - CUET
Contact:

Post by Moni » Wed Jul 02, 2003 4:51 pm

Yeap! Here is the link............ done by Suman...............isn't it Ok ???

http://acm.uva.es/board/viewtopic.php?t=1725
ImageWe are all in a circular way, no advances, only moving and moving!

Post Reply

Return to “C”