there are lots of sort routines you can find online. So, this will accept an arbitrary number of names:
n=0
name="x"
while name ≠ ""
read name
if name≠"" then names[n++] = name
end while
snames = sort names,n
while n>0 print names[n--]
Write the pseudocode for an application that accepts enter eight friends’ first names and displays them in alphabetical order
1 answer