Looking for help with C++ game of life program. Will pay or make donation for tutor.

Please support our C++ advertiser: Intel Parallel Studio Home
Reply

Join Date: Dec 2006
Posts: 18
Reputation: nicolivolkov is an unknown quantity at this point 
Solved Threads: 0
nicolivolkov nicolivolkov is offline Offline
Newbie Poster

Looking for help with C++ game of life program. Will pay or make donation for tutor.

 
0
  #1
Dec 15th, 2006
Hi all,

I looking for somebody to help me through a final class program. I would be happy to pay somebody to tutor me through this or make a donation. I am not looking for somebody to just give me the answer, but I DEFINITELY need help. It is due on Monday. Only two people in the entire class have had any success with it. I'm pretty lost. If someone can help me, please let me know. I have all the info pertaining to the assignment. Thanks alot.
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 5,266
Reputation: iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold 
Solved Threads: 377
Featured Poster
iamthwee's Avatar
iamthwee iamthwee is offline Offline
Posting Expert

Re: Looking for help with C++ game of life program. Will pay or make donation for tutor.

 
0
  #2
Dec 15th, 2006
What's the problem then?
*Voted best profile in the world*
Reply With Quote Quick reply to this message  
Join Date: Dec 2006
Posts: 18
Reputation: nicolivolkov is an unknown quantity at this point 
Solved Threads: 0
nicolivolkov nicolivolkov is offline Offline
Newbie Poster

Re: Looking for help with C++ game of life program. Will pay or make donation for tut

 
0
  #3
Dec 15th, 2006
THe actual assignment is 3 pages long with requirements, so I'll just give you the cut and dry version:

Write a program that plays the game of life. Create a class with the name "boolMatrix" for storing and processing a two dimensional array of bool values. We need to read in a dat file that basically contains a pair of coordinates representing the row / col of the locations containing the true values (live cells). the array must be 20 by 20 to start. We need 8 member functions.

This is basically it, with a bunch more specs about whether a cell lives in the future generations and such... The problem is that this is the first time we have used either classes or 2 d arrays and I'm having a terrible time using them together.
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 5,266
Reputation: iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold 
Solved Threads: 377
Featured Poster
iamthwee's Avatar
iamthwee iamthwee is offline Offline
Posting Expert

Re: Looking for help with C++ game of life program. Will pay or make donation for tutor.

 
0
  #4
Dec 15th, 2006
1. Plan what you think you need to do on paper, i.e NO CODE
2. Draw a flow chart, how does your program go from start to finish?
3. Play with 2d arrays, filling and printing them out.
4. Learn how a basic class can be built.
5. Think about what methods your class will have.
*Voted best profile in the world*
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 5,266
Reputation: iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold 
Solved Threads: 377
Featured Poster
iamthwee's Avatar
iamthwee iamthwee is offline Offline
Posting Expert

Re: Looking for help with C++ game of life program. Will pay or make donation for tutor.

 
0
  #5
Dec 15th, 2006
When you've actually got some code together post back. Have a go.
*Voted best profile in the world*
Reply With Quote Quick reply to this message  
Join Date: Dec 2006
Posts: 18
Reputation: nicolivolkov is an unknown quantity at this point 
Solved Threads: 0
nicolivolkov nicolivolkov is offline Offline
Newbie Poster

Re: Looking for help with C++ game of life program. Will pay or make donation for tutor.

 
0
  #6
Dec 15th, 2006
Well I have spent quite a bit of time working on this... I just don't really understand it and the class is online and the teacher is never available for help. Which is probably why 22 people have dropped. Here's what I've come up with so far. It's not much and I truthfully don't understand exactly where I'm going with it.

Is there a way to attach the entire assgnment?
  1. #include <iostream>
  2. #include <fstream>
  3. #include "boolMatrix.h"
  4. using namespace std;
  5. const int num_rows = 20;
  6. const int num_cols = 20;
  7. boolMatrix booleanMatrix[row_num][col_num];
  8. int row = 0;
  9. int col = 0;
  10.  
  11.  
  12. boolMatrix::boolMatrix()
  13. {
  14. for(int row = 0; row < num_rows; row++){
  15. for(int col = 0; col < num_cols; col++){
  16. return false;
  17. }
  18. }
  19. }
  20.  
  21.  
  22. boolMatrix boolMatrix::get( boolMatrix booleanMatrix)const
  23. {
  24. return booleanMatrix (row, col);
  25. }
  26.  
  27. void boolmatrix::set (boolMatrix booleanMatrix)
  28. {
  29. ifstream infile("location_alive.dat");
  30. int row, col;
  31.  
  32.  
  33. while(infile){
  34. infile >> row >> col;
  35. booleanMatrix.set(row,col,"TRUE");
  36. }
  37. }
Last edited by ~s.o.s~; Dec 15th, 2006 at 9:47 pm. Reason: Added code tags learn to use them yourself.
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 5,266
Reputation: iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold 
Solved Threads: 377
Featured Poster
iamthwee's Avatar
iamthwee iamthwee is offline Offline
Posting Expert

Re: Looking for help with C++ game of life program. Will pay or make donation for tutor.

 
0
  #7
Dec 15th, 2006
Please post your code with code tags. See the watermark in the background.

Ok, briefly tell me what all your member functions are for your class and what you expect them to do?
*Voted best profile in the world*
Reply With Quote Quick reply to this message  
Join Date: Apr 2006
Posts: 5,051
Reputation: John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold 
Solved Threads: 332
Team Colleague
John A's Avatar
John A John A is offline Offline
Vampirical Lurker

Re: Looking for help with C++ game of life program. Will pay or make donation for tutor.

 
0
  #8
Dec 15th, 2006
At the bottom of the "Advanced reply", you can attach a number of different types of files. And if you do post the code right in your post, please use Code tags. (More info in my sig)

Just a note: you're not allowed to return anything in a class's constructor, which is what you're trying to do in boolMatrix::boolMatrix()

Can't see any more until you post the other files... but it looks good.
"Technological progress is like an axe in the hands of a pathological criminal."

All my posts may be freely redistributed under the terms of the MIT license.
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 5,266
Reputation: iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold iamthwee is a splendid one to behold 
Solved Threads: 377
Featured Poster
iamthwee's Avatar
iamthwee iamthwee is offline Offline
Posting Expert

Re: Looking for help with C++ game of life program. Will pay or make donation for tutor.

 
0
  #9
Dec 15th, 2006
Also what does BoolMatrix.h look like?

What does your dat file look like.

Post an example please and use code tags.

[edit]I need sleep, I'll be back in the morning.[/edit]

Remember plan it first before you do any coding!
Last edited by iamthwee; Dec 15th, 2006 at 8:01 pm.
*Voted best profile in the world*
Reply With Quote Quick reply to this message  
Join Date: Dec 2006
Posts: 18
Reputation: nicolivolkov is an unknown quantity at this point 
Solved Threads: 0
nicolivolkov nicolivolkov is offline Offline
Newbie Poster

Re: Looking for help with C++ game of life program. Will pay or make donation for tut

 
0
  #10
Dec 15th, 2006
Hi ProgrammerJoe,

I uploaded the file, I hope it worked. Please let me know. Inside the main assignment are links to the input file. I'm not sure if they were cut out when I attached though.

I'm not sure what "tags" are. I haven't used them thus far in C++ other CSS HTML and ASP yes, but C++ not sure what they are.

I'm basically stuck at this point.
Attached Files
File Type: doc Project 5.doc (32.5 KB, 51 views)
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the C++ Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC