473,394 Members | 1,481 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

need help with MBA course project

My apologies to those of you who are more advanced Visual C++ .NET
programmers, but I am working on a project for an MBA course that is
condensed into an eight-week schedule, and I need help getting a
program up and running with proper files and documentation to be handed
in for a grade (on Microsoft Visual Studio .NET 2003).

I am being graded on how well I incorporate advanced C++ features such
as inheritance, polymorphic programming, exception-handling, components
of the Standard Library, etc. as well as whether the program runs and
compiles correctly and is properly documented. Being relatively new to
both C++ and Visual Studio .NET, I am not sure what my header files,
source files, and resource files will look like. I have followed the
basic examples in the online tutorials that Microsoft offers, but I
want to make sure I'm getting the details right for a program more
complex than a "Hello World" program.

What I am trying to develop is a very simplified simulation of Conway's
biological game of life. Keep in mind that this is for an MBA course
and not for an advanced science course. The rules of the game I'd like
to incorporate into the program are, for a cluster of cells:
1. Any cell with fewer than two neighbors dies.
2. Any cell with more than three neighbors dies.
3. Any cell with two or three neighbors lives.

I am thinking that I would like the program to be a variation on a card
shuffling and dealing simulation--an array of data structures--that
appears on p. 1062 of Harvey Deitel's textbook, C++: How to Program
(Fifth Edition) (unless anyone can think of a better model). Instead of
using the class "DeckofCards" as my array of data structures, I will
use the class "ClusterOfCells". My objects will be the individual
cells.

I would like to use polymorphic programming in the sense that each
cell's identity will change (it will be a dead cell or live cell) based
on the inputs or functions that act on it. I am debating whether some
basic selection/repetition statements are the best way the develop the
basic logic of the game, or if there is some way to incorporate virtual
functions with dynamic binding into the program, so that each cell is
exhibiting the behavior of surviving or dying based on conditions in
the cell's environment. Regardless of whether my functions are virtual
or static, I will need them to act on a cell so that they communicate
to a cell how many neighbors it has and then cause the cell to live or
die based on the number of neighbors.

Finally, I would like to incorporate the "remove" and "replace"
algorithms from the Standard Library so that a dead cell is removed
from the cluster of cells and is replaced by a live cell. And again, I
need to incorporate exception handling, document everything properly,
and make sure everything compiles and runs correctly.

Any help would be greatly appeciated, as I am under a tight deadline!

Jun 16 '06 #1
4 2175
ro*******@gmail.com wrote:
[...]
What I am trying to develop is a very simplified simulation of
Conway's biological game of life. Keep in mind that this is for an
MBA course and not for an advanced science course. The rules of the
game I'd like to incorporate into the program are, for a cluster of
cells:
1. Any cell with fewer than two neighbors dies.
2. Any cell with more than three neighbors dies.
3. Any cell with two or three neighbors lives.

[...]

Any help would be greatly appeciated, as I am under a tight deadline!


Here is my contribution: your rules are missing the one that governs
the creation of new life in an empty cell.

Beyond that, I am not sure what kind of help you expect. You describe
relatively well what *you* need to do.

V
--
Please remove capital 'A's when replying by e-mail
I do not respond to top-posted replies, please don't ask
Jun 16 '06 #2
* ro*******@gmail.com:
I would like to use polymorphic programming in the sense that each
cell's identity will change (it will be a dead cell or live cell) based
on the inputs or functions that act on it. I am debating whether some
basic selection/repetition statements are the best way the develop the
basic logic of the game, or if there is some way to incorporate virtual
functions with dynamic binding into the program, so that each cell is
exhibiting the behavior of surviving or dying based on conditions in
the cell's environment. Regardless of whether my functions are virtual
or static, I will need them to act on a cell so that they communicate
to a cell how many neighbors it has and then cause the cell to live or
die based on the number of neighbors.


It's not a good idea to abstract up low level things. It's not a good
idea to start abstracting at all, before you have enough of a grip on
the problem to be able to do it without any fancy stuff. It's not a
good idea to decide in advance what tools you'll bring to bear on a
problem you don't yet understand.

Since you're off on entirely the wrong foot, the only advice I can offer
is to not think in terms of /a/ program: you need to first create a
smallest possible text only program that does this thing with no more
abstraction than absolutely necessary, just to understand what you're
trying to do. The program should work. And you should understand why.

Then work iteratively, creating a second program, and a third.

--
A: Because it messes up the order in which people normally read text.
Q: Why is it such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?
Jun 16 '06 #3
ro*******@gmail.com wrote:
I am being graded on how well I incorporate advanced C++ features such
as inheritance, polymorphic programming, exception-handling, components
of the Standard Library, etc. as well as whether the program runs and
compiles correctly and is properly documented.

What I am trying to develop is a very simplified simulation of Conway's
biological game of life. Keep in mind that this is for an MBA course
and not for an advanced science course. The rules of the game I'd like
to incorporate into the program are, for a cluster of cells:
1. Any cell with fewer than two neighbors dies.
2. Any cell with more than three neighbors dies.
3. Any cell with two or three neighbors lives.


It is supposed to be:

3. Any cell with two neighbors does not change state.
4. Any cell with three neighbors lives.

Having implemented Conway's life quite recently I would say using advanced
C++ features on it is a bit of a stretch. I certainly did not use
polymorphism in any way. STL wise std::vector and std::fill was pretty much
it.

The one thing that can be a bit of a challenge is performance and that does
not seem to be relevant for your grade.

My advice would be to look for a different problem if you have a choice.

Jun 16 '06 #4
"Alf P. Steinbach" wrote:
I would like to use polymorphic programming in the sense that each
cell's identity will change (it will be a dead cell or live cell) based
on the inputs or functions that act on it. I am debating whether some
basic selection/repetition statements are the best way the develop the
basic logic of the game, or if there is some way to incorporate virtual
functions with dynamic binding into the program, so that each cell is
exhibiting the behavior of surviving or dying based on conditions in
the cell's environment. Regardless of whether my functions are virtual
or static, I will need them to act on a cell so that they communicate
to a cell how many neighbors it has and then cause the cell to live or
die based on the number of neighbors.


It's not a good idea to abstract up low level things. It's not a good
idea to start abstracting at all, before you have enough of a grip on the
problem to be able to do it without any fancy stuff. It's not a good idea
to decide in advance what tools you'll bring to bear on a problem you
don't yet understand.

Since you're off on entirely the wrong foot, the only advice I can offer
is to not think in terms of /a/ program: you need to first create a
smallest possible text only program that does this thing with no more
abstraction than absolutely necessary, just to understand what you're
trying to do. The program should work. And you should understand why.

Then work iteratively, creating a second program, and a third.


I set this aside earlier in the week and have finally read the OPs post. I
would loudly say AMEN to what is said here. Instead of attacking the
problem, you have gotten fascinated with a bunch of fancy-shamcy buzzwords.
You said it was for an MBA for God's sake! There are probably a
mini-bazillion Game of Life programs that work perfectly well and were
written by guys who knew zilch about virtual functions and dynamic binding.
Jun 18 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
by: Sam | last post by:
we are running windows 2003 server. it has NET framework installed, but doesn't have Visual Studio etc. installed on it. i created a new sulotion/project on my development pc and FTP'd it up to our...
3
by: visual basic dummy | last post by:
I have taken a course at the local college. It is called Advanced Languages and this course will cover C++, Perl and Javascript. I must pass this course. In January/Feb we covered a 1000+page...
11
by: Mark | last post by:
Hi, For the last 2 years I've been developing vehicle tracking/telemetric software for a company as a self employed individual. The project is quiet big, and is going to be there flagship...
3
by: google | last post by:
I have a database with four table. In one of the tables, I use about five lookup fields to get populate their dropdown list. I have read that lookup fields are really bad and may cause problems...
23
by: Adam | last post by:
I am coding a microkernel based off of Tanebaum's theroy. For Isis to be extensible, fast, and secure, it has been decided it will be a microkernel. Not in the old Mach sense of the word, but in...
10
by: Frank | last post by:
I've done this a few times. In a solution I have a project, Say P1, and need another project that will contain much code that is similar to that of P1. I hope no one gets hung up on why I...
2
by: micangello | last post by:
i need ideas on what my final year project can be about i have studied 2 years of pure math (advanced calculus and algebra, topology, statistics..... ) i then switched ot computer science now...
14
by: Leah | last post by:
I am a student and are required to build a website that provide services (client-server). I need advice in choosing approach or to be exact the methodology that appropriate for such development....
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.