hi Gaurav, every is suggesting u the same ...do sth for lazy people ! It's really a good idea. But if u will be doing others homework for others it's not gonna help u very much,as u can earn sm money...
Type: Posts; User: amite
hi Gaurav, every is suggesting u the same ...do sth for lazy people ! It's really a good idea. But if u will be doing others homework for others it's not gonna help u very much,as u can earn sm money...
Thn x "CommonTater".......
On linux system it gives warning message while on windows system it gives error message when i was using GCC but with VC++ compiler it's all fine .
Thanx evry1 :-)
Yes,i think i would have go with GMP.............
please suggest me other solution of my problem ....
Though i am not full time programmer and don't know the standards of C programming ,i believe and do programming to accomplish my task............
int A[x];//it won't work on each compiler (old one)...
I tried the following on windows(codeblock) and linux(gcc) :
#include <stdio.h>
#include <stdint.h>
int main()
{
uint64_t x;
unsigned long long y;
unsigned long int...
the number i have is 600851475143.
Even this satement give error.When i use 600851475 then it give the result.I am using codeblock on windows.
the number i have is 600851475143.
Even this satement give error.When i use 600851475 then it give the result.
@Salem : I know the algo of the problem but main problem is how to handle the large number.As we can't use double data type cause we need to use % operator.
Can any provide me a little code...
Use calloc() or malloc() for dynamic memory allocation.With calloc u won't need to use memset() as all the memory location allocated are initialized by 0.Ex:
#include <stdlib.h>
int main()
{
...
If the number is greater than 2^32(4294967296)then how to determine whether is it prime or not? Ex:Is 4437864713 a prime number ?