Question

3. Name Search Modify the Sorted Names program that you wrote for exercises #2 so it...

3. Name Search Modify the Sorted Names program that you wrote for exercises #2 so it allows you to search the array for a specific name.

design a flowchart for it

exercises 2 is as follow:

Sorted Names

Design a program that allows the user to enter 20 names into a String array. Sort the array in ascending (alphabetical) order and display its contents.

Pseudocode for number 3 as follow:

  1. Initialize i=0
  2. Get the name to search for
  3. If i<20

Check if string at index i is equal to the specific name

If so ,print it and exit the loop

Else i+=1

        Loop till i reaches 20

Need a flowchart

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Completely confused about your question:

Check if string at index i is equal to the specific name

If so ,print it and exit the loop

Else i+=1

        Loop till i reaches 20

It is not pseudo code for Design a program that allows the user to enter 20 names into a String array. Sort the array in ascending (alphabetical) order and display its contents.

Please mention what u needed in comment block.

Clearly give the question, and mention what do you want flow chart or program..

Please comment clearly.

Add a comment
Know the answer?
Add Answer to:
3. Name Search Modify the Sorted Names program that you wrote for exercises #2 so it...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Design a program that allows the user to enter 5 names into a String array. Sort...

    Design a program that allows the user to enter 5 names into a String array. Sort the array in ascending (alphabetical) order and display its contents. Search the array for a specific name that the user wants. For this problem you will be submitting python homework, no flowchart

  • This is with microsoft studio visual basic Sorted Names Design a program that allows the user...

    This is with microsoft studio visual basic Sorted Names Design a program that allows the user to enter 20 names into a String array. Sort the array in ascending (alphabetical) order and display its contents.

  • SortAndSearch.cpp – Objectives: Binary Search and Selection sort You are given a list of 20 names...

    SortAndSearch.cpp – Objectives: Binary Search and Selection sort You are given a list of 20 names as follows: {"Collins, Bill", "Smith, Bart", "Michalski, Joe", "Griffin, Jim",                         "Sanchez, Manny", "Rubin, Sarah", "Taylor, Tyrone", "Johnson, Jill",                         "Allison, Jeff", "Moreno, Juan", "Wolfe, Bill", "Whitman, Jean",                         "Moretti, Bella", "Wu, Hong", "Patel, Renee", "Harrison, Rose",                   "Smith, Cathy", "Conroy, Pat", "Kelly, Sean", "Holland, Beth"}; Write a program to sort and display the names in alphabet order (use selection sort). The program prompts...

  • Write C programs for the following: 1. Modify the sorting program you wrote in Lab 2...

    Write C programs for the following: 1. Modify the sorting program you wrote in Lab 2 so that it is modular. Write a function called sort that accepts an integer array, sorts it, and returns the sorted array to the main function. Call this function from the main program. In addition, write a subroutine called print_array that accepts an integer array and prints it out in this format: The array is [01 2 3456 7 8 9] Use this function...

  • in c++ Program 1 Write a program that sorts a vector of names alphabetically using the...

    in c++ Program 1 Write a program that sorts a vector of names alphabetically using the selection sort and then searches the vector for a specific name using binary search. To do that, you need to write three functions I. void selSort (vector string &v: sorts the vector using selection sort 2. void display (const vector <string & v): displays the vector contents . int binSearch (const vector <ing& v, string key): searches the vector for a key returns the...

  • Must be written in C++ Display results and comments Write a program that sorts a vector...

    Must be written in C++ Display results and comments Write a program that sorts a vector of names alphabetically using the selection sort and then searches the vector for a specific name using binary search. To do that, you need to write three functions: 1. void selSort (vector <string> & v): sorts the vector using selection sort 2. void display (const vector <string> & v): displays the vector contents 3. int binSearch (const vector <string> & v, string key): searches...

  • Using the following Java program, modify the code so that every time you run your program,...

    Using the following Java program, modify the code so that every time you run your program, it generates random numbers for your array, and then prints it (insertion sort) import java.awt.Graphics; import java.applet.Applet; public class SortingProg extends Applet { int a[] = { 55, 25, 66, 45, 8, 10, 12, 89, 68, 37 }; public void paint(Graphics g)     {       print(g,"Data items in original order",a,25,25);       sort();       print(g,"Data items in ascending order",a,25,55);     } public void sort() {...

  • Modify the program that you wrote for the last exercise in a file named Baseball9.java that...

    Modify the program that you wrote for the last exercise in a file named Baseball9.java that uses the Player class stored within an array. The program should read data from the file baseball.txt for input. The Player class should once again be stored in a file named Player.java, however Baseball9.java is the only file that you need to modify for this assignment. Once all of the input data from the file is stored in the array, code and invoke a...

  • Please help!! (C++ PROGRAM) You will design an online contact list to keep track of names...

    Please help!! (C++ PROGRAM) You will design an online contact list to keep track of names and phone numbers. ·         a. Define a class contactList that can store a name and up to 3 phone numbers (use an array for the phone numbers). Use constructors to automatically initialize the member variables. b.Add the following operations to your program: i. Add a new contact. Ask the user to enter the name and up to 3 phone numbers. ii. Delete a contact...

  • //bubble sort implementation// Fig 6.15 with simplified convention for the for loop. #define _CRT...

    //bubble sort implementation// Fig 6.15 with simplified convention for the for loop. #define _CRT_SECURE_NO_WARNINGS //for windows os only #include <stdio.h> #include <stdlib.h> // Fig. 6.15: fig06_15.c // Sorting an array's values into ascending order. #include <stdio.h> #define SIZE 10 // function main begins program execution int main(void) {    // initialize a    int a[SIZE] = { 2, 6, 4, 8, 10, 12, 89, 68, 45, 37 };    printf("Data items in original order");    // output original array    for (int i = 0;...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT