Writer a program that allows the user to enter

Assignment Help C/C++ Programming
Reference no: EM13168660

Writer a program that allows the user to enter an unknown number of characters, stores those characters in a data structure (a vector) and then prints the values to the screen.

an example :

witness my exciting first use of vectors!

Enter as many letter as you like, enter ! to quit.

enter a letter: b

enter a letter: u

enter a letter: r

enter a letter: r

enter a letter: p

enter a letter: !

Great! you entered: burrp

The frist character is : b

The last character is : p

 

 

 

Note: the exclamation point was never stored in the vector.

Goal: recognize that vector objects allow greater flexibility that arrays and how to use a vector in a program.

you do not need to specify size when using vectors.

 

 

Reference no: EM13168660

Questions Cloud

What are the approximate percentages of each : the atomic mass of chlorine is listed as 35.454 amu on the periodic table. it has two naturally occurring isotopes, Cl-35 and Cl-37. what are the approximate percentages of each?
Compute the work done by the helium gas : The temperature is held at 271 K. Calculate the work done by the gas(in joules). to give the appropriate sign
Find the volume of hydrogen evolved : Find the volume of hydrogen evolved when 3.25g of zinc granules react completely with excess hydrochloric acid solution (Zn=65)
What is the specific gravity of this mineral : What is the hardness of this mineral? What is the specific gravity of this mineral? show your calculations. Using all these properties, identify this mineral?
Writer a program that allows the user to enter : Writer a program that allows the user to enter an unknown number of characters, stores those characters in a data structure (a vector) and then prints the values to the screen.
Determine the number of moles of oxygen that react complete : Determine the number of moles of oxygen that react completely with 8.0 moles of C2H6 based on the following balanced equation.
State an enzyme-catalyzed reaction produces a product : An enzyme-catalyzed reaction produces a product that has a maximum absorbance at 412 nm. The extinction coefficient is 4000 M^-1 cm^-1. A 10-to-1 dilution of the enzyme is made and 20 microliter of the dilution are put into a cuvette with 80 micro..
Compute the binding energy of electrons : the maximum velocity of the ejected electrons is 3.45 multiplied by 105 m/s. Calculate the binding energy of electrons to the magnesium surface.
What is the volume of the hydrogen gas : what is the volume of the hydrogen gas (at25oC and 100KPA) needed to produce 51.1g of ammonia?

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Write test program to call function several times for gcd

Greatest common divisor of two integers is largest integer which will evenly divide both integers. Implement this function in assembly language and write test program which calls function several times, passing it different values.

  Write program using c language to find page fault

Write program using c language to find page fault for individual processes, group of processes and system as whole using following system call int sys_pgfltstats(pid_t pid,int flag,pf_info_struct *info).

  Once the user enters a 0

Once the user enters a 0 you will exit the loop, close the file and execute the code as previously designed until you have displayed all of the scores and the average handicap.

  Generate a set of 75 random integers in the range -26 to + 4

Write a program that will generate a set of 75 random integers in the range -26 to + 42. The program

  Program to tell you how many months it will take to pay off

write a program to tell you how many months it will take to pay off any loan, as well as the total amount of interest paid over the life of the loan.

  Program that asks the user to enter the number of miles

Write a C - program that asks the user to enter the number of miles traveled and the number of gallons of gasoline consumed. It should then calculate and display the miles-per-gallon value. Confine your output to 1 decimal place.

  The counter each time it''s clicked

Write a simple script that contains a button and a counter in a div. The button's event handler should increment the counter each time it's clicked.

  Design a program that asks for the number of fat grams

Starting out with Programming logic and design 3rd Author Tony Gaddis - Pg 279, PE 3 Fat Grams Calculator

  The stack-based routing scheme

the stack-based routing scheme you are to have a stack of maze locations.

  Variables should be private and the class functions public

All the class variables should be private and the class functions public. The class functions should be implemented in a file Inventory.cpp which should be linked with the inventory.hpp file.

  Output the even numbers from 1 to 10 in ascending order

Output the even numbers from 1 to 10 in ascending order, then the odd numbers from 10 to 1 in descending order: 2 4 6 8 10 9 7 5 3 1. in C++

  The second argument to the function is the string

The function fnUserBinaryInputX has 2 input arguments, each is a string. The first string is the "prompt" string displayed to the user when asked to enter a string. The second argument to the function is the string to compare the user entered stri..

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd