1. This assignment deals with processing arrays.The double array balances shows a list of bank balances for a bank.You will copy and paste these balances into your program.You are NOT allowed to change any values unless instructed to do so in class.The values will all be zero or more except for the sentinel record.Often times software developers will end a set of data with a flag value whose only purpose is to mark the end of the data.The value -999 is the sentinel marker and indicates the end of the dataset.Any results calculated must NOT include the sentinel record’s value.

    double balances[]={23.2,56,23,91.8,234.2,293.1,.93,97.8,.19,56.2,198.2,193.9,46.0,34.5,
    47,495,93.67,45,0,0,9,0,24,0.35,0,27.5,89.23,293.9,98.293,0,23,23,24.1,
    25.5,25.56,9.99,10,10.5,10.5,23,2.23,27.5,10.5,37.8,26,98,101.01,1093.2,
    45,25.5,10.5,8.29,.91,1.98,27.27,28.28,90,91.01,91,47.3,56.78,98.76,65.43,2.1,
    567.22,55.22,77,11.29,35.77,888.4, 93,94,95.1,97.1,997.11,45.45,44.24,87.5,10.5,
    0,0,3.09, 7829.1,26.19,562.9,2,3,6, 39.4, 82.88,2837.2,0,1.01,2.03,3,3.3,33,333,1333.3, 5.1,4.95,
    -999};

    Each record has a corresponding name as according to its index. In order to get the name for a particular index, you can pass that index to the accountName() function and receive back a name. If the index is invalid, the name “NO NAME” will be returned, otherwise, the corresponding name for that index will be returned. The function signature is:string accountName(int in);where in is the index of the account.You must calculate and show the following:1) The number of account values2) The average of the set of balances.3) The least value that is greater than zero.4) The account holders of the greatest TWO balances.5) The percentage of balances that are zero.6) The names of the account holders who have a zero balance.You are to copy and paste the following function into your code. You are NOT to make any sense of it, simply understand what it does from the description.

    string accountName(int ii){
    static vector<string> *lst=NULL;
    if(lst == NULL) { //cout << “Do new!n”; lst = new vector<string>;
    lst->push_back(“Leigha Ekberg”); lst->push_back(“Gustavo Engelbrecht”); lst->push_back(“Paul Barclay”); lst->push_back(“Mamie Bornstein”); lst->push_back(“Jung Chuang”); lst->push_back(“Tracy Claxton”);lst->push_back(“Rosy Golding”); lst->push_back(“Stanley Lavigne”); lst->push_back(“Yuk Amezquita”); lst->push_back(“Dora Holcomb”); lst->push_back(“Fonda Manners”); lst->push_back(“Tamika Andreas”); lst->push_back(“Kelsey Mathew”); lst->push_back(“Corrin Caviness”); lst->push_back(“Daren Whisnant”); lst->push_back(“Angila Kucharski”); lst->push_back(“Samara Digby”); lst->push_back(“Abdul Gummer”); lst->push_back(“Jamila Kina”); lst->push_back(“Sun Buonocore”); lst->push_back(“Jacki Proffit”); lst->push_back(“Dwain Mell”); lst->push_back(“Keva Yellowhair”); lst->push_back(“Gertie Folkerts”); lst->push_back(“Cassi Mysliwiec”); lst->push_back(“Logan Stelle”); lst->push_back(“Osvaldo Pugsley”); lst->push_back(“Jane Castle”);lst->push_back(“Kermit Yann”); lst->push_back(“Christeen Tedrow”); lst->push_back(“Etsuko Mcnutt”); lst->push_back(“Kandra Sinclair”); lst->push_back(“Scarlett Ghent”); lst->push_back(“Luana Nyberg”); lst->push_back(“Kizzy Mungia”); lst->push_back(“Julius Roe”); lst->push_back(“Earnest Mcmasters”); lst->push_back(“Janel Daniele”); lst->push_back(“Treena Haak”); lst->push_back(“Deidra Kilmer”); lst->push_back(“Mica Stephen”); lst->push_back(“Maxine Ready”); lst->push_back(“Shayne Luebke”); lst->push_back(“Shanae Korman”); lst->push_back(“Latonia Tindall”); lst->push_back(“Synthia Otten”); lst->push_back(“Tommye Carignan”); lst->push_back(“Rea Haislip”); lst->push_back(“Jonelle Styons”); lst->push_back(“Alita Bartholow”); lst->push_back(“Ronny Clark”); lst->push_back(“Ashton Mack”); lst->push_back(“Jim McDonald”); lst->push_back(“Charles The Great”); lst->push_back(“Robert Masters”); lst->push_back(“Silli Pants”); lst->push_back(“Donald Duck”); lst->push_back(“Precious Tate”); lst->push_back(“Alicyn Wonder”); lst->push_back(“Mariln Lamb”); lst->push_back(“Oscar Unger”); lst->push_back(“Jerry Butler”); lst->push_back(“Nils McGee”); lst->push_back(“Brian Patterson”); lst->push_back(“Luke Solo”); lst->push_back(“Eric VonSchatt”); lst->push_back(“Jay Bees”); lst->push_back(“Tucker Taylor”); lst->push_back(“Buck Owens”); lst->push_back(“Robert Blake”);lst->push_back(“Parker Nonce”); lst->push_back(“Peyton Clark”); lst->push_back(“Sunshine Wilson”);lst->push_back(“Tuesday Sharlotte”); lst->push_back(“Evans Brightman”); lst->push_back(“Joseph Steele”); lst->push_back(“Matthew Marks”); lst->push_back(“Kelly Astaire”); lst->push_back(“Michael Smith, III”); lst->push_back(“Muddy Waters”); lst->push_back(“Tyrone Stanfords”); lst->push_back(“Mitchell County”); lst->push_back(“Ethan Brucks”); lst->push_back(“Cains Qi”); lst->push_back(“Exter Feeny”); lst->push_back(“Sunny Binghamton”); lst->push_back(“Sean White”); lst->push_back(“Anthony Adverse”); lst->push_back(“Carl Nicholson”); lst->push_back(“Felix Katz”); lst->push_back(“Rebecca Black”); lst->push_back(“Steve Wachira”);lst->push_back(“Shelby Dinkins”); lst->push_back(“Mundo Pinky”);lst->push_back(“Sherrel Mason”); lst->push_back(“Glenn Tompkins”);lst->push_back(“Carol Hawkes”); lst->push_back(“Ezekiel Bryant”); lst->push_back(“Pearl Peshe”); lst->push_back(“Meadowlark Lemon”); lst->push_back(“Ron E. Grace”);lst->push_back(“Melvin Middleton”); }
    if(ii < 0 || ii >= lst->size()) return “NO NAME”;
    return (*lst)[ii];
    } //end of function

 
Do you need a similar assignment done for you from scratch? We have qualified writers to help you. We assure you an A+ quality paper that is free from plagiarism. Order now for an Amazing Discount!
Use Discount Code "Newclient" for a 15% Discount!

NB: We do not resell papers. Upon ordering, we do an original paper exclusively for you.

Save your time - order a paper!

Get your paper written from scratch within the tight deadline. Our service is a reliable solution to all your troubles. Place an order on any task and we will take care of it. You won’t have to worry about the quality and deadlines

Order Paper Now