SHOW ME THE CODE !

1586555214444.webp

I got this
BOOST y = e ^ (pi * sqrt(163)) = 262537412640768183.98118196127384561629
the difference 183.98118196127384561629
all values expressed in terms of the boost library
 
View attachment 34588
I got this
BOOST y = e ^ (pi * sqrt(163)) = 262537412640768183.98118196127384561629
the difference 183.98118196127384561629
all values expressed in terms of the boost library
My C++ Boost code gives
262537412640768743.999999999999250072597198185688879353856337336990862707537410378210647910118607313

which is correct.

This number was discovered in 1859 by the mathematician Charles Hermite.[7] In a 1975 April Fool article in Scientific American magazine,[8] "Mathematical Games" columnist Martin Gardner made the hoax claim that the number was in fact an integer, and that the Indian mathematical genius Srinivasa Ramanujan had predicted it—hence its name.
 
Last edited:
My C++ Boost code gives
262537412640768743.999999999999250072597198185688879353856337336990862707537410378210647910118607313
which is correct.
This number was discovered in 1859 by the mathematician Charles Hermite.[7] In a 1975 April Fool article in Scientific American magazine,[8] "Mathematical Games" columnist Martin Gardner made the hoax claim that the number was in fact an integer, and that the Indian mathematical genius Srinivasa Ramanujan had predicted it—hence its name.
Probably It is.I will go over my code and increase the precision. What brings the attention of this problem is that standard library could give wrong results for particular cases, this could help to new C/C++ programmers. Best Regards Doctor Duffy, Stay at Home!
 
If you run my code you get the correct answer :-) Maybe you are mixing your types?
 
I am using Microsoft Visual Studio Community 2019 Versión 16.6.3
Is the executable 64 bits? how to know, is there a C/C++/boost instruction to know the version of the compiled process?
How to set MVS IDE to output executable either 32 bit or 64 bit, is it possible?
I know that any CPU will give you a 64 bit process on win64; I need to load load a 32 bits DLL.
how can I force a 'x86' to a 32 bits process which has no issues loading 32 bits DLLs.
 
Is there a way a C++ program can take advantage of a multicore processor?

Newbie question..

absolutely in C++11. threads, tasks and futures.

Discussed in my C++ 2018 book and QN Advanced C++ course.

Recommend doing some research.

//
Just got an 8-core machine today. What can I in heaven's name use it for? No idea.
 
Last edited:
Newbie question..

absolutely in C++11. threads, tasks and futures.

Discussed in my C++ 2018 book and QN Advanced C++ course.

Recommend doing some research.

//
Just got an 8-core machine today. What can I in heaven's name use it for? No idea.
That is a great machine the new one you have,
8 core =: 16 máximum numbers of threads.
reg instruction seems to be deprecated
Besides threads?
I have a program that is several K of source code (MS visual Studio 2019 - Windows) I was wondering how to tell the OS my program has a priority, something like in Unix/Linux.
 
Last edited:
That is a great machine the new one you have,
8 core =: 16 máximum numbers of threads.
reg instruction seems to be deprecated
Besides threads?
I have a program that is several K of source code (MS visual Studio 2019 - Windows) I was wondering how to tell the OS my program has a priority, something like in Unix/Linux.
Yes, I'm in the lap of luxury.

Maybe Boost Process (heavyweights tasks)?

 
C++:
    int xx = 2;
    int yy = xx++*++xx;
    int xx2 = 2;
    int yy2 = --xx2-++xx2;
    std::cout << "yy, yy2: " << yy << "," << yy2 << '\n';
 
Back
Top Bottom