Question

Create a program that allows the user to input a list of first names into one...

Create a program that allows the user to input a list of first names into one array and last names into a parallel array. Input should be terminated when the user enters a sentinel character. The output should be a list of emial addresses where the address is of the following form: [email protected]


Declare FirstName[100] as String
Declare LastName[100] as String
Declare email as String
Declare K as Integer
Declare index as Integer


Write "Enter first and last name."
Write "Enter * to exit"

Input FirstName[index]
While FirstName != "*"
   If index >= OR FirstName[index]=="*"
   Write "Enter last name"
   Input LastName[index]
   Set email[index] to FirstName[index]+"."+LastName[index]+"@mycollege.edu"
   Set index to index + 1
   Write "Enter first name"
   Write "Enter * to exit"
   Input FirstName[index]
   End While
   Then loop = 1
   While loop >=index
   Output email[loop]
   Set loop to loop + 1
   End While
   End If
   End Then

Is this how I would write the pseudocode for this? Can someone make some tweaks or input. This is done in raptor also.

Homework Answers

Answer #1

Declare FirstName[100] as String
Declare LastName[100] as String
Declare emails[100] as String
Declare size as Integer
Declare index as Integer

While True
   Write "Enter first and last name."
   Write "Enter * to exit"
   Input FirstName[index]
   If FirstName=="*"
       Break
   End If
Input LastName[index]
Set emails[index] to FirstName[index]+"."+LastName[index]+"@mycollege.edu"
Set index to index + 1
   Set Size to Size + 1  
End While
For I 0 to Size
   Write Emails[I]
End FOr

Know the answer?
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
Similar Questions
Phone number lookup Design a program that has two parallel arrays: a string array named people...
Phone number lookup Design a program that has two parallel arrays: a string array named people that is initialized with the names of seven of your friends, and a string array named phoneNumbers that is initialized with your friends phone numbers. The program should allow the user to enter a persons name (or part of a persons name). it should then search for that person in the people array. If the person is found, it should get that persons phjone...
11. First and Last Design a program that asks the user for a series of names...
11. First and Last Design a program that asks the user for a series of names (in no particular order). After the final person's name has been entered, the program should display the name that is first alphabetically and the name that is last alphabetically. For example, if the user enters the names Kristin, Joel, Adam, Beth, Zeb, and Chris, the program would display Adam and Zeb. I need help with creating a python code for this using a sentinel...
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. (python)
Write a complete Java program which prompts the user of the program to input his/her first...
Write a complete Java program which prompts the user of the program to input his/her first name, then prompts the user for the middle initial and finally prompts the user for the last name. As indicated, there are three prompts to the user. The program should output the user’s name with the first name first, followed by the middle initial, and the last name last, all on one line (with appropriate spacing). If you could also pinpoint exactly where to...
C++ Create a program that will use pointers to determine the average (to 1 decimal place)...
C++ Create a program that will use pointers to determine the average (to 1 decimal place) of a series of grades entered into an array. You can assume a maximum of 15 students and the user will end input with a sentinel value. Make sure to use pointer increment and a pointer comparison while loop, and not array notation or array index numbers or offsets. You will use a function called getgrades. Send the array name (a pointer constant) to...
3. Create a program which allows the user to swap individual words in an input string....
3. Create a program which allows the user to swap individual words in an input string. Given a string of input, your program should count and store the number of words in a 2D array. The user can then select the index of the words they want to swap. Your program should swap those two words and then print the entire string to ouput. • Use string prompt "> ". • Use indices prompt "Enter two indices: ". • Remove...
Write a Java program that prompts the user to enter his/her name (first and last). Names...
Write a Java program that prompts the user to enter his/her name (first and last). Names are often expressed alphabetically as last name comma space first name. Display the user's alphabetical name and its length. Then output the user's initials. Finally, display the ASCII values of the initials with a space between them. Sample Output (input shown in italics) Enter your full name Jane Doe Your alphabetical name Doe, Jane is 9 characters long Your initials are JD ASCII of...
Using the Prelude to Programming book, complete Programming Challenge 2 on page 463. Save your file...
Using the Prelude to Programming book, complete Programming Challenge 2 on page 463. Save your file as LASTNAME_FIRSTNAME_M07HW2. (worth 15 points) Create a program that allows the user to input a list of first names into one array and last names into a parallel array. Input should be terminated when the user enters a sentinel character. The output should be a list of email addresses where the address is of the following form: [email protected]. please help!!!!
Write a program that accepts an input string from the user and converts it into an...
Write a program that accepts an input string from the user and converts it into an array of words using an array of pointers. Each pointer in the array should point to the location of the first letter of each word. Implement this conversion in a function str_to_word which returns an integer reflecting the number of words in the original string. To help isolate each word in the sentence, convert the spaces to NULL characters. You can assume the input...
Arrays, loops, functions: Lotto Element Repeated Function Write a function that that takes as parameters an...
Arrays, loops, functions: Lotto Element Repeated Function Write a function that that takes as parameters an array of ints, an int value named element, and an int value named end. Return a bool based on whether the element appears in the array starting from index 0 and up to but not including the end index. Generate Random Array Write a function that takes as parameters an array of integers and another integer for the size of the array. Create a...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT