Placeholder

CISS 350 Programming Assignment 7 Compare Two Implementations of a Priority Queue

$19.00

Description

Programming Assignment 7
Your assignment is to write and compare two implementations of a priority queue whose highest priority element is the one with the smallest key value. The elements have the following declarations:
The first implementation uses a minimum heap. You need to modify the heap operations to keep the minimum, rather than maximum, element in the root. The comparison function should compare key fields.
The second implementation uses a linear linked list, whose elements are ordered by key value.
Test Data
Create a data set that contains 50 items with priorities generated by a random-number generator.
Comparing the Implementations
To compare the operations, you must modify the Enqueue and Dequeue operations to count how many elements are accessed (compared or swapped, in the case of reheaping) during its execution.
Write a driver to Enqueue and Dequeue the 50 test items and print out the number of elements accessed for the Enqueue and Dequeue operations. Run your driver once with each implementation.
Deliverables
A listing of specification and implementation files for both priority queue implementations
A listing of your driver
A listing of your test data
A listing of the output from both runs
A report comparing the number of elements accessed in executing each operation.
SCREENSHOTS
SOLUTION
PAYMENT
ENTIRE COURSE
The solution includes a Visual Studio (c++) project
Attachments [Move over files to preview content of those files]
CISS_350_Programming_Assignment_7.zip (4.40 MB)
CISS350-Programming-Assignment-7-Output.png
CISS350-Programming-Assignment-7-Screenshot.png
CISS350-Programming-Assignment-7-Thumb.png
Visual Studio C++ Project
CISS350Assignment7
CISS350Assignment7
CISS350Assignment7.cpp
CISS350Assignment7.vcxproj
CISS350Assignment7.vcxproj.filters
Debug
CISS350A.CEB550EF.tlog
CISS350Assignment7.lastbuildstate
CISS350Assignment7.obj
CISS350Assignment7.pch
stdafx.obj
vc120.idb
vc120.pdb
ReadMe.txt
Report.out
stdafx.cpp
stdafx.h
targetver.h
Test.dat
CISS350Assignment7.opensdf
CISS350Assignment7.sdf
CISS350Assignment7.sln
CISS350Assignment7.v12.suo
Debug
CISS350Assignment7.exe
CISS350Assignment7.ilk
CISS350Assignment7.pdb
ipch
ciss350assignment7-15bb52f8
ciss350assignment7-8c9bcc6.ipch
Preview CISS350Assignment7.cpp
xxxxx xxxxxxxxx xxx;
xxxxxxx xxxxxx xxx{
xxx xxx;
xxx *xxxx;
} Node; int n; // number items int a[MaxSize]; // store all item input int MinHeap[MaxSize]; // define min heap int Nheap; // number items current in heap Node *List; // define linear linked list whose elements are ordered by key value ofstream Fout(OutputFile); // enqueue means to add an item to the queue, generally at the “back” of the queue. This can sometimes be called “push” // numsteps is number steps using to Enqueue void Enqueue(int key, int &numsteps){ int child, parent; //Increase size of heap
xxxxx++;
xxxxx = xxxxx;
xxxxx (xxxxx > 1){ // xxxxx xx xxx xxxx
xxxxxx = xxxxx / 2;
xxxxxxxx++; // xxxxxxxx xxxxxxxx
xx (xxxxxxx[xxxxxx] > xxx){
Preview ReadMe.txt
========================================================================
xxxxxxx xxxxxxxxxxx : xxxx350xxxxxxxxxx7 xxxxxxx xxxxxxxx
========================================================================
xxxxxxxxx xxx xxxxxxx xxxx xxxx350xxxxxxxxxx7 xxxxxxxxxxx xxx xxx.
This file contains a summary of what you will find in each of the files that make up your CISS350Assignment7 application.
CISS350Assignment7.vcxproj This is the main project file for VC++ projects generated using an Application Wizard. It contains information about the version of Visual C++ that generated the file, and
xxxxxxxxxxx xxxxx xxx xxxxxxxxx, xxxxxxxxxxxxxx, xxx xxxxxxx xxxxxxxx xxxxxxxx xxxx xxx
xxxxxxxxxxx xxxxxx.
xxxx350xxxxxxxxxx7.xxxxxxx.xxxxxxx
xxxx xx xxx xxxxxxx xxxx xxx xx++ xxxxxxxx xxxxxxxxx xxxxx xx xxxxxxxxxxx xxxxxx.
xx xxxxxxxx xxxxxxxxxxx xxxxx xxx xxxxxxxxxxx xxxxxxx xxx xxxxx xx xxxx xxxxxxx
Preview stdafx.h
// xxxxxx.x : xxxxxxx xxxx xxx xxxxxxxx xxxxxx xxxxxxx xxxxx,
// xx xxxxxxx xxxxxxxx xxxxxxx xxxxx xxxx xxx xxxx xxxxxxxxxx, xxx
// xxx xxxxxxx xxxxxxxxxxxx
//
#pragma once
#include “targetver.h”
#include
#include
// xxxx: xxxxxxxxx xxxxxxxxxx xxxxxxx xxxx xxxxxxx xxxxxxxx xxxx
Preview targetver.h
#pragma once
// Including SDKDDKVer.h defines the highest available Windows platform.
// If you wish to build your application for a previous Windows platform, include WinSDKVer.h and // set the _WIN32_WINNT macro to the platform you wish to support before including SDKDDKVer.h.
// xxx xxx _xxx32_xxxxx xxxxx xx xxx xxxxxxxx xxx xxxx xx xxxxxxx xxxxxx xxxxxxxxx xxxxxxxxx.x.
#xxxxxxx
Price: $19
Buy Now
Checkout
Added to cart
Add to Cart
Checkout
Added to cart
FLASH SALE
$89
$113
Save $24
CISS350 Entire Course
Get Entire Course
You May Also Like:
CISS 350 Entire Course
CISS 350 Programming Assignment 1 Checkout System
CISS 350 Programming Assignment 2 Computer Dating Service
CISS 350 Programming Assignment 3 Local Medical Clinic
CISS 350 Programming Assignment 4 Circular Linked List
CISS 350 Programming Assignment 5 Towers of Hanoi
CISS 350 Programming Assignment 6 Police Department

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.