Questions: 5 839

Free Answers by our Experts: 5 231

Many students face the C++ problems and have no idea how to cope with them. They start worrying about their results and feel miserable because of that. We don’t want you to be sad because of your C++ problems and want provide you with the C++ answers you are looking for. We know how many C++ questions are there in your head and we also know how important it is for you to get good marks. Let our service to look for the C++ answers for all your questions and make you sure that home assignment may be not that bad as you may think!

Ask Your question

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search & Filtering

1. Write a program to store integer elements in an array named test of size 10 with initial values (5,9,57,3,9,21,57,6,9,3) and print it.

 2. Modify the program to read to display the array contents in reverse order. 

 3. Modify the program to find the sum of all elements of the array. 

4. Modify the program to copy the elements from the test array into another array named testcopy. 

8. Modify the programs to count and display the frequency of each element of array test.

9. Modify the program to find the maximum and minimum element in array test.  



Write a program that reads a person’s name in the following format: first name, then middle name or initial, and then last name. The program then outputs the name in the following format: last name, first name. middle initial. For example the input Mary Average User should produce the output User, Mary A.Your program should work the same and place a full stop after the middle initial even if the input did not contain a full stop. Your program should allow for users who give no middle name or initial. In that case, the output of courses contains no middle name or initial. For example, the input Mary User should produce the output User, Mary Your program should also accept names in lowercase, uppercase or a mix of lowercase and uppercase, and display that in the correct format, e.g. if the input is mArY average USER should produce the output User, Mary A.


You have to write a program to read an input file character by character to help Peter solve the following activity in his activity book. The paragraph below is given: We h2pe that 32u e5723ed the acti4it3. A6ter 32u ha4e c2mpleted the acti4it3, 0e5d 32ur re0ult t2: The Acti4it3 C2mpetiti25, Bett3 Da4i0 0treet 99, Auckla5d Park, 989, a5d 0ta5d a cha5ce t2 wi5 a hamper c250i0ti51 26 c2l2uri51 a5d acti4it3 b22k0, c2l2uri51 pe5cil0 a5d pe50. Create an input file activity.dat with the paragraph above. The numbers 0 to 7 have to be replaced as follows: 0 must be replaced by s 1 must be replaced by g 2 must be replaced by o 3 must be replaced by y 4 must be replaced by v 5 must be replaced by n 6 must be replaced by f 7 must be replaced by j Ask the user to input the names of the input and output files. Read the input file character by character, and write the character (if it stays the same) to the output file, or write the changed character to the output file. Call your output file competition.txt


Write a C++ program which perform the following:


1.Create a Class Sequence

2.Create a Private Static Data Member and initialize it with value zero

3.Create a Public Static Member Function , funcStatic ( )to access the static data member

4.Now, access the static member function in Main(), and using Constructor print the following sequence: 0 1 3 6 10 15 21 28



The following program shows queue implementation using Array. In the main( ) function, the queue is inserted 5 times, i.e. up to its maximum capacity. However, though the deQ( ) function has been executed, the program fails to insert a new element (value=21) into the queue. Modify the program so the queue can be filled up to its maximum capacity at any time. 



Write a C++ program which perform the following:


1.Create a Class factorial

2.Create Private Member Variable and initialize it with Member initialization list and with value zero

3.Now, take inputs from user

4.Create a Public Member Function Calculate( ) outside the class , to calculate the factorial of a given input

5.Create another Public Member Function Result( ) outside the class, to print the results on screen

6.Now, create a constant object of the class which perform following:

a. Passes the values to the Calculate( ) function

b. Call the Result( )

function to show result



Imagine BAGADI - a publishing company that markets both books, Tape/drive (audiocassette and Videocassette) versions of its works. Create a class publication that stores the title (a string) and price (type float) of a publication. From this class derive two classes: book, which adds a page count (type int), and tape, which adds a playing time in minutes (type float). Each of these three classes should have a getdata() function to get its data from the user at the keyboard, and a putdata() function to display its data. Write a main() program to test the book and tape/drive classes by creating instances of them, asking the user to fill in data with getdata(), and then displaying the data with putdata() as per the order based on the user choice either playing time or number of pages. (Try to use the concept of Constructors, Destructors & Function Overloading).


Write a C++ program which perform the following:

1. Create a Class Sequence

2. Create a Private Static Data Member and initialize it with value 

zero

3. Create a Public Static Member Function, funcStatic( ) to access 

the static data member

4. Now, access the static member function in Main(), and using 

Constructor print the following sequence:

0 1 3 6 10 15 21 28


Write a C++ program which perform the following:

1. Create a Class factorial

2. Create Private Member Variable and initialize it with Member 

initialization list and with value zero

3. Now, take inputs from user

4. Create a Public Member Function Calculate( ) outside the class, 

to calculate the factorial of a given input

5. Create another Public Member Function Result( ) outside the 

class, to print the results on screen

6. Now, create a constant object of the class which perform following: 

a. Passes the values to the Calculate( ) function 

b. Call the Result( ) function to show result


Write a C++ program which perform the following:

1. Create a Class factorial

2. Create Private Member Variable and initialize it with Member

initialization list and with value zero

3. Now, take inputs from user

4. Create a Public Member Function Calculate( ) outside the class,

to calculate the factorial of a given input

5. Create another Public Member Function Result( ) outside the

class, to print the results on screen

6. Now, create a constant object of the class which perform following:

a. Passes the values to the Calculate( ) function

b. Call the Result( ) function to show result


LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS