Each of my Computer Science classes require a final project of complexity commensurate with what is learned in the class. The computer language used is the language studied during the semester. Currently, that is either Java or C++. This document is divided into the following areas. Deciding on a project and selecting team members should be performed simultaneously.
- Decide on Team Members
- Select a Project
- Create and/or Open a GitHub Account
- Create an Initial Design and Assign Sections
- Create Schedule
- Present Design and Schedule
- Create Stubs for All Modules in Project
- Daily Scrums
- Final Submittal of Code and Presentation
Decide on Team Members
With whom would you like to work? Choose one to two other members of your team wisely. Each person should contribute to the project. Decide on your team at the same time your are selecting your project (step 2). Send either a chat message on Teams or an e-mail to [email protected].
Select a Project
What project would your team like to develop. Choose wisely. It should be related to what you have developed so far. Examples are Mancala in CSC160 C++ and Connect Four in CSC161 Java using JavaFX. Make it complex enough to make it interesting, but not so complex that it cannot be done within the time left in the semester.
Create and/or Open a GitHub Account
Repositories are vital to creating a large project. It allows code to be saved in an easily accessible location that saves the code as it is revised and allows the user to access any revision that might be needed for any purpose. The preferred Revision Control System is GitHub. Please go to this location and either login or create an account and then login. Be sure your name is unique and easy to remember. GitHub is connected to all Development Environments like Visual Studio for C++ and IntelliJ Idea for Java. GitHub uses Git on your local system as the interface. Be sure to download Git to your system.
Integrate GitHub with Microsoft Visual Studio 2019
Here is how to integrate GitHub into Microsoft Visual Studio.
Create an Initial Design and Assign Sections
There are several formats for design. The main attribute is that it has enough information to be helpful. One method I would recommend is Object Oriented Design Using UML (Universal Modeling Language). An example is Rubber Ducky Corporation. Know what you want to do and then start deciding what that is. If you are using Classes, use UML Diagrams to describe their interfaces. An example of a UML follows. It has a Person Class with two classes that inherit from the person class, a Customer Class and a Personnel Class. Just for your information, the symbols are as follows:
- # – Protected item, accessible by Class and all Subclasses.
- – – Private item, accessible within the Class only
- + – Public item, accessible by everyone
The above diagram was created from Microsoft Word. There are several tools that are available that are better than Word. A list of twenty-eight is at BEST 28 UML Tools in 2020. A single one which one of my students recommended is app.diagrams.net. This last one looks interesting. It allows saving the files to one of your online repositories like Google Drive or Microsoft One Drive. This makes life easier but it also requires you to log into your storage device through their interface. When you have added the Git/GitHub integration, you can start creating the needed classes. The first example is for C++ and Visual Studio.
Create Schedule
On the bottom of the Rubber Ducky Corporation page is a list of tasks to be done from most to least important. Go ahead and fill it out and decide how long it would take to do each task. Build a schedule based on your analysis.
Present Design and Schedule
Put together your design and put into slide form. On 30 November 2020, please make your presentations.
Create Stubs for All Modules in Project
Set up your GitHub account within your team. Decide which modules you will be writing in each daily scrum. Decide on the order in which your team will write these modules. The modules that are scheduled last, write interfaces that accept expected arguments and return something appropriate. The logic does not need to be written yet. But a stub needs to be written so that the modules that are being written can call the unwritten module and get something reasonable in return. The best way to show how this is completed is by example.
C++
To use a class method, both the header including the needed Prototype and the file containing the code must be written. Here is the header file:
#pragma once
/* BoardSample.h
* Wayne Cook
* 17 November 2020
* Purpose:
* Create a sample class to show how to create a stub in developing one method to use
* in your code development.
*/
#ifndef __BOARDSAMPLE__
#define __BOARDSAMPLE__
#include <random>
using namespace std;
// Set up the class in which the method will reside.
class BoardSample
{
public:
BoardSample();
~BoardSample();
/* playerMove(int &)
* Input - pointer to the player variable which indicates whose turn it is
* Output - returns in the player variable whose turn is next
* 1 - player 1
* 2 - player 2
* 0 - side empty
*/
void playerMove(int&);
private:
};
#endif
then the code must be written. In this case I use a random number generator to create the player value of 0, 1, or 2:
/* BoardSample.cpp
* Wayne Cook
* 17 November 2020
* Purpose:
* Create a sample class to show how to create a stub in developing one method to use
* in your code development.
*/
#include "BoardSample.h"
// Default constructor and destructor
BoardSample::BoardSample()
{
}
BoardSample::~BoardSample()
{
}
/* playerMove(int &player)
* Input - pointer to the player variable which indicates whose turn it is
* Output - returns in the player variable whose turn is next
* 1 - player 1
* 2 - player 2
* 0 - side empty
*/
void BoardSample::playerMove(int &player) {
/* Set player equal to 0, 1, or 2 for simulating the results of a completed method
* after code completion. A random number divided by 3 gives the desired results.
*/
player = rand() % 3;
}
Java
Java is a bit simpler. It only takes one code file.
/* BoardSample.cpp
* Wayne Cook
* 17 November 2020
* Purpose:
* Create a sample class to show how to create a stub in developing one method to
* use
in your code development.
*/
import java.util.Random;
public class BoardSample {
Random random = new Random();
/* playerMove(int player)
* Input - pointer to the player variable which indicates whose turn it is
* Output - returns in the player variable whose turn is next
* 1 - player 1
* 2 - player 2
* 0 - side empty
*/
int playerMove(int player) {
int retVal = 0;
/* Set player equal to 0, 1, or 2 for simulating the results of a completed
* method
after code completion. A random number divided by 3 gives the
* desired results.
*/
retVal = random.nextInt(3);
}
}
Daily Scrums
Scrums are usually done for two weeks sessions. They are based on the Agile Manifesto. In normal development cycles, a Scrum last two weeks. The name is based on how Rugby is played. Read the Scrum Manifesto to have a better idea of how to run your daily scrums. Each day submit a description of each task you have completed and what is scheduled to be done the following 24 hours.
Final Submittal of Code and Presentation
Be prepared for presentations on the 14th and 15th of December. Have your software ready to be submitted and demonstrated.