Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Calc program updated Again!
Goto page Previous  1, 2
 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
seeplusplus
Grandmaster Cheater
Reputation: 0

Joined: 28 Oct 2007
Posts: 562
Location: cracking accounts

PostPosted: Tue Nov 13, 2007 4:27 pm    Post subject: Reply with quote

lol ok jani I'll work on being able to hold pi in a memory location. Very Happy
_________________
I am xwallflowerx...this will probably be deleted soon...
Back to top
View user's profile Send private message
XxOsirisxX
Grandmaster Cheater Supreme
Reputation: 0

Joined: 30 Oct 2006
Posts: 1597

PostPosted: Tue Nov 13, 2007 8:22 pm    Post subject: Reply with quote

Jani wrote:
XxOsirisxX wrote:
That why ppl put a limit. Also, there are no reason to wants a number that high, else you attemp to crash the program.
Exactly! They limit you! Where's your freedom? It's like you couldn't buy more than 5 different stuff from your local shop.. What's the point?

Oh yeh, btw.. Do you think that no one needs long numbers either then? What's the point of having long numbers, if you can't do anything with them? What if you need accurate numbers for something really important calculation, (I can't think up you doing anything important, tho ;D) and then mess it up, because you calculated the sum with rounded numbers? zomg, like 1000 ppl died because of your rounding, GG.

PS. He wanted practise, there's some pratise for him. What's the point of reinventing the wheel, if not practising? Someone has already done it and you could leech him/her off, but you wouldn't learn anything else than leeching.

PPS. Getting a bit offtopic, but whatever.


No offence, but most of that you said, is really pointless.

is not about if 5 or 1000, is about long numbers, really long ones, which you will NEVER will use in a real case or those that you said. You can't make an good example, because there are no way to need that amount of numbers, and even handle it if it's about something real, like food or somethings else.

He wants to LEARN. If you can get a bse in learning, is much easier than make something without knowing. Like, how DOS where made from nothing and stuff.. but, if you can get a guide, is not about leeching, is about learning. Rolling Eyes

_________________

Back to top
View user's profile Send private message
TheSorc3r3r
I post too much
Reputation: 0

Joined: 06 Sep 2006
Posts: 2404

PostPosted: Tue Nov 13, 2007 8:28 pm    Post subject: Reply with quote

What if you wanted to calculate the number of electrons in the universe?

burrnnnn

_________________


Don't laugh, I'm still learning photoshop!
Back to top
View user's profile Send private message
XxOsirisxX
Grandmaster Cheater Supreme
Reputation: 0

Joined: 30 Oct 2006
Posts: 1597

PostPosted: Tue Nov 13, 2007 8:31 pm    Post subject: Reply with quote

TheSorc3r3r wrote:
What if you wanted to calculate the number of electrons in the universe?

burrnnnn


Then get a microscope and start counting Rolling Eyes

_________________

Back to top
View user's profile Send private message
Flyte
Peanuts!!!!
Reputation: 6

Joined: 19 Apr 2006
Posts: 1887
Location: Canada

PostPosted: Tue Nov 13, 2007 8:46 pm    Post subject: Reply with quote

Jani had a great idea. It teaches you how to make and manage your own custom data types.
Back to top
View user's profile Send private message
seeplusplus
Grandmaster Cheater
Reputation: 0

Joined: 28 Oct 2007
Posts: 562
Location: cracking accounts

PostPosted: Tue Nov 13, 2007 9:07 pm    Post subject: Reply with quote

Flyte wrote:
Jani had a great idea. It teaches you how to make and manage your own custom data types.


custom data types?

_________________
I am xwallflowerx...this will probably be deleted soon...
Back to top
View user's profile Send private message
Jani
Grandmaster Cheater
Reputation: 2

Joined: 29 Dec 2006
Posts: 804

PostPosted: Wed Nov 14, 2007 12:38 pm    Post subject: Reply with quote

XxOsirisxX wrote:
No offence, but most of that you said, is really pointless.

is not about if 5 or 1000, is about long numbers, really long ones, which you will NEVER will use in a real case or those that you said. You can't make an good example, because there are no way to need that amount of numbers, and even handle it if it's about something real, like food or somethings else.
You will use those in mathematics, cryptography, etc. Get family with those stuff and you'll notice. If you're not planning to be any good at math/comps/etc, feel free to live in your limited world. I'm not going to do that. I want to live freeeeeeee...! And die hard.

btw.. Doesn't MSN Messenger's default character limit annoy you? ;) If it does, you know what I'm talking about. And if you've done anything a bit advanced maths, you've noticed that the display of your calc isn't long enough or it has to do some rounding to display the scientific value.

XxOsirisxX wrote:
He wants to LEARN. If you can get a bse in learning, is much easier than make something without knowing. Like, how DOS where made from nothing and stuff.. but, if you can get a guide, is not about leeching, is about learning. :roll:
Try to make one with addition, substitution, multiplication and division. Remember that you've to manage dynamically the memory, because you can't know how long is the number ;) For learning, making something like the example I gave is hella good, trust me, I've noticed it.

Flyte wrote:
Jani had a great idea. It teaches you how to make and manage your own custom data types.
Not exactly that. It teaches you how to do a for-loop AND YOU NEED TO THINK WHAT ARE YOU DOING. I bet you can't do a long num calc without brains (not literally :P). Thinking is the most hardest part in programming, because you can always look at reference, how does a function work and so on...
Back to top
View user's profile Send private message
seeplusplus
Grandmaster Cheater
Reputation: 0

Joined: 28 Oct 2007
Posts: 562
Location: cracking accounts

PostPosted: Wed Nov 14, 2007 1:18 pm    Post subject: Reply with quote

Now It can hold massive numbers.

Someone help with GUI please. Pm me if you want to help. The tutorials don't make much sense.

_________________
I am xwallflowerx...this will probably be deleted soon...
Back to top
View user's profile Send private message
rapion124
Grandmaster Cheater Supreme
Reputation: 0

Joined: 25 Mar 2007
Posts: 1095

PostPosted: Wed Nov 14, 2007 8:04 pm    Post subject: Reply with quote

Easy way around this, ask the user if he/she wants to calculate a large number(over 2^32). Then, just use real or extended type to store those numbers.

Btw, a GUI is hard to make in C++. C++ is object-oriented but that doesn't mean it has a good way to make GUIs for you. Unless you use Visual C++, a GUI will be hard. You will have to manually type all the properties you want your GUI to have such as size, location, etc.
Back to top
View user's profile Send private message
Jani
Grandmaster Cheater
Reputation: 2

Joined: 29 Dec 2006
Posts: 804

PostPosted: Thu Nov 15, 2007 8:27 am    Post subject: Reply with quote

Your code doesn't even compile. You can't use a switch-case thing with doubles.

seeplusplus wrote:
Now It can hold massive numbers.
Doesn't look like so.. How much is 29857982578927676573737 added to 324873483748354273735727? (Gimme the exact number.)It's 354731466327281950309464
Back to top
View user's profile Send private message
seeplusplus
Grandmaster Cheater
Reputation: 0

Joined: 28 Oct 2007
Posts: 562
Location: cracking accounts

PostPosted: Thu Nov 15, 2007 8:46 am    Post subject: Reply with quote

Jani wrote:
Your code doesn't even compile. You can't use a switch-case thing with doubles.

seeplusplus wrote:
Now It can hold massive numbers.
Doesn't look like so.. How much is 29857982578927676573737 added to 324873483748354273735727? (Gimme the exact number.)It's 354731466327281950309464


It compiles with dev c++



cacl.JPG
 Description:
Works.
 Filesize:  39.37 KB
 Viewed:  4894 Time(s)

cacl.JPG



_________________
I am xwallflowerx...this will probably be deleted soon...
Back to top
View user's profile Send private message
Jani
Grandmaster Cheater
Reputation: 2

Joined: 29 Dec 2006
Posts: 804

PostPosted: Thu Nov 15, 2007 8:51 am    Post subject: Reply with quote

29857982578927676573737 + 324873483748354273735727 isn't even close to 6.2*10^22. It's 354731466327281950309464. So, you haven't added the large number feature thing yet.

My error: seeplusplus.cpp
seeplusplus.cpp(13): error: expression must have integral or enum type
switch(answer){

-> Double isn't integral or enum. Standards ftw :p

EDIT: tested with g++ (MingW is based on it) with same results:
test.cpp: In function 'int main()':
test.cpp:15: error: switch quantity not an integer

To get the large number stuff work, you need to mess with arrays.

@Others: see, it isn't that easy. If you want to practise your skills, make a calc with large number support.
Back to top
View user's profile Send private message
rapion124
Grandmaster Cheater Supreme
Reputation: 0

Joined: 25 Mar 2007
Posts: 1095

PostPosted: Thu Nov 15, 2007 5:32 pm    Post subject: Reply with quote

Fix the errors yourself. When you use someone else's source, expect errors. If you are sufficient at C++, then you should be able to find the small error and fix it.
Back to top
View user's profile Send private message
seeplusplus
Grandmaster Cheater
Reputation: 0

Joined: 28 Oct 2007
Posts: 562
Location: cracking accounts

PostPosted: Thu Nov 15, 2007 8:14 pm    Post subject: Reply with quote

rapion124 wrote:
Fix the errors yourself. When you use someone else's source, expect errors. If you are sufficient at C++, then you should be able to find the small error and fix it.


It compiles perfectly fine with dev.

But I will change the data types.

_________________
I am xwallflowerx...this will probably be deleted soon...
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites