Blackjack Using Objects and Dynamic Memory Allocation


Data Structures


The purpose of the assignment is to create a black-jack game where the user is the “player” and your program is the “dealer” (or “house”). The objectives of this assignment are to (1) gain experience with dynamic memory allocation, (2) gain experience with creating appropriate data structures (including objects), (3) gain experience with “looking up” and using external functions, and (4) learn proper coding styles and how to properly document code.

This assignment can be used early on in the semester, but students should understand basic constructs, standard I/O, and how to perform dynamic memory allocation.


Bill Eberle


design document, code, comments, pseudo-code, documentation, reflection, tech report

Assignment Duration

Two Weeks

Communication Skill

reading, writing

Technical Skill

implementation, tools, design, research, linear data structures, program design, comments, documentation, programming language basics, data types and variables, pointers and memory management, standard library integration, research, problem solving

Workplace Scenario

Technical Task: As a software developer in the work force, you may be faced with developing code using techniques or third-party APIs that you did not develop or are unfamiliar. This may require some research to not only discover potential source code or libraries, but also understand how they work and the advantages and disadvantages of using them.
Professional Setting: Student works for a software company.
Professional Role: Software Engineer.
Deliverable: Design document (with design decisions)
Real-world Audience: Team Lead and peers.
How the Audience will USE the student's communication: The team lead and peers will use the student's design (decisions) document to do the following: (1) make suggestions as to possible design alternatives, and (2) determine the feasibility of the design choices.
Additional Notes: In this assignment, you will need to research and read about functions that will provide appropriate string I/O capabilities. In addition, you will need to look up how to use the external function random_shuffle. In a real-time environment, the ability to dynamically allocate and de-allocate memory is a vital concept. The ability to allocate and de-allocate memory (as well as directly access memory) makes C/C++ a powerful language – one of the primary reasons that most operating systems are developed in C. Thoroughly understanding how to handle memory is important to mastering C/C++, and thus key to developing solid data structures and algorithms that efficiently use system memory.

In the real-world, the customer is usually more familiar with their domain than the software engineer. Sometimes, the software engineer may need to research their customer’s domain so that they can further understand the problem. In this assignment, if you do not understand the game of Blackjack, you must research how it is played

Team Size




Bill Eberle, “Blackjack Using Objects and Dynamic Memory Allocation,” Incorporating Communication Outcomes into the Computer Science Curriculum, accessed September 25, 2017, http://cs-comm.lib.muohio.edu/items/show/39.


Creative Commons License


Allowed tags: <p>, <a>, <em>, <strong>, <ul>, <ol>, <li>