586 Answered Questions for the topic C++
06/23/20
Design a class template, Collection, that stores a collection of Objects (in an array), along with the current size of the collection.
Provide public functions isEmpty, makeEmpty, insert, remove, and contains.contains(x) returns true if and only if an Object that is equal to x ispresent in the collection.
06/23/20
Rehashing requires recomputing the hash function for all items in the hash table. Read more.....
Since computing the hash function is expensive, supposeobjects provide a hash member function of their own, and each objectstores the result in an additional data member the rst time the...
more
C++
06/17/20
data structure program of c++
Based on the header file given below;Write the code for main( ) function to decode the secret message as given in the array of characters below by using the concept of Stack Linked List. You are...
more
06/16/20
File Compression and multi-dimensional arrays
Compression Algorithm:One method of compressing a file is to recognize repeated digits and replace the runs ofrepetition with a number representing the repetition length. For instance for a line in...
more
06/16/20
File Compression and multi-dimensional arrays
"Need a new c++ code done in Dev-C++ 5.11""Compiler set to configure TDM-GCC 4..9.2 64-bit Release"Scenario (need c++ coding)A simple matrix could be used to store data about images by using 1’s...
more
06/07/20
File Compression and multi-dimensional arrays
Scenario (need c++ coding)A simple matrix could be used to store data about images by using 1’s and 0’s to represent darkand light shades of color similar to a bitmap. You will find a file data.txt...
more
File compression and multi-dimensional array
Scenario A simple matrix could be used to store data about images by using 1’s and 0’s to represent darkand light shades of color similar to a bitmap. You will find a file data.txt under your...
more
06/03/20
File Compression and multi-dimensional arrays
ScenarioA simple matrix could be used to store data about images by using 1’s and 0’s to represent darkand light shades of color similar to a bitmap. You will find a file data.txt under your...
more
C++ Programming
06/02/20
File Compression and multi-dimensional arrays Scenario
A simple matrix could be used to store data about images by using 1’s and 0’s to represent darkand light shades of color similar to a bitmap. You will find a file data.txt under your assignment3 on...
more
05/17/20
read a student file into an array of structs, determine grades, sort the array and print it out.
Use the Student struct shown below.Read the input file and store the data in an array of structs. The input file contains student records and one heading line.Write code to determine the grade for...
more
C++ Programming
05/12/20
practice using dynamic memory allocation, c-string functions,
Read a dictionary word file into an array of c-strings. You will need to dynamically allocate memory for each word in the dictionary. The word file contains 23,907 words.Sort the dictionary.Reading...
more
05/06/20
C++ program-Binary Tree
I need help creating a binary tree in C++. The given source code is below in the google drive link. https://drive.google.com/open?id=1tMTLHBX3S3r8GCDFNquOAEm5cpwqcTWb
04/27/20
Online shopping cart
(1) Create three files to submit:
ItemToPurchase.h - Class declaration
ItemToPurchase.cpp - Class definition
main.cpp - main() function
Build the ItemToPurchase class with the following...
more
04/22/20
C++ code on odd and even number using vector
Create 2 Vectors using the For StatementVector 1 = will have ODD numbers from 1 to 99➔vec1 – vector nameVector 2 = will have EVEN numbers from 2 to 100➔vec2 – vector namePrint Vector 1 & 2 from...
more
04/17/20
Find the maximum value and minimum value in milesTracker. Assign the maximum value to maxMiles, and the minimum value to minMiles.
Find the maximum value and minimum value in milesTracker. Assign the maximum value to maxMiles, and the minimum value to minMiles. Sample output for the given program:
Min miles: -10
Max miles:...
more
04/17/20
Write a loop that subtracts 1 from each element in lowerScores if the original element was greater than 0, and otherwise just assigns the element with 0.
Write a loop that subtracts 1 from each element in lowerScores if the original element was greater than 0, and otherwise just assigns the element with 0. Ex: lowerScores = {5, 0, 2, -3} becomes {4,...
more
04/17/20
Write a program that first gets a list of integers from input.
Write a program that first gets a list of integers from input. The input begins with an integer indicating the number of integers that follow. That list is followed by two more integers...
more
04/17/20
Write a program that reads a list of words. Then, the program outputs those words and their frequencies.
Write a program that reads a list of words. Then, the program outputs those words and their frequencies. The input begins with an integer indicating the number of words that follow. Assume that the...
more
04/17/20
Write a program that reads a list of integers, and outputs those integers in reverse.
Write a program that reads a list of integers, and outputs those integers in reverse. The input begins with an integer indicating the number of integers that follow. For coding simplicity, follow...
more
04/12/20
Assign numMatches with the number of elements in userValues that equal matchValue.
Assign numMatches with the number of elements in userValues that equal matchValue. userValues has NUM_VALS elements. Ex: If userValues is {2, 2, 1, 2} and matchValue is 2 , then numMatches should...
more
04/12/20
Write a for loop to populate vector userGuesses with NUM_GUESSES integers.
Write a for loop to populate vector userGuesses with NUM_GUESSES integers. Read integers using cin. Ex: If NUM_GUESSES is 3 and user enters 9 5 2, then userGuesses is {9, 5, 2}.#include...
more
04/12/20
Write a program that reads a list of integers, and outputs the two smallest integers in the list, in ascending order.
Write a program that reads a list of integers, and outputs the two smallest integers in the list, in ascending order. The input begins with an integer indicating the number of integers that...
more
04/12/20
Given a sorted list of integers, output the middle integer. Assume the number of integers is always odd.
Given a sorted list of integers, output the middle integer. Assume the number of integers is always odd.Ex: If the input is:
2 3 4 8 11 -1 (a negative indicates the end), the output is:4The maximum...
more
04/12/20
Write a program that first gets a list of integers from input.
Write a program that first gets a list of integers from input. The input begins with an integer indicating the number of integers that follow. Then, get the last value from the input, which...
more
04/12/20
Output each floating-point value with two digits after the decimal point, which can be achieved by executing cout << fixed << setprecision(2); once before all other cout statements.
Output each floating-point value with two digits after the decimal point, which can be achieved by executingcout << fixed << setprecision(2); once before all other cout statements.(1)...
more
Still looking for help? Get the right answer, fast.
Ask a question for free
Get a free answer to a quick problem.
Most questions answered within 4 hours.
OR
Find an Online Tutor Now
Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.