Write a program that takes an integer input n from the user and then asks the user to enter n strings. All the n strings must contain just the English alphabets (may contain both capital and small...


Can Anyone help me solve this question Asap Thank you!


Write a program that takes an integer input n from the user and then asks the user to enter n<br>strings. All the n strings must contain just the English alphabets (may contain both capital and<br>small letters).<br>In case a user enters any other character for a particular string, the program should ask the user<br>to enter that particular string again. After the user is done entering those n strings, the program<br>should sort those all n strings alphabetically (considering only the first element of the string for<br>sorting). Small alphabets have more precedence than capital alphabets, so small alphabets<br>come first. Display the sorted output on the screen.<br>Sample Program:<br>Enter a value for n: 7<br>Enter string 1: HaiDer<br>Enter string 2: BismaH<br>Enter string 3: aleEm<br>Enter string 4: Aleena<br>Enter string 5: SALman<br>Enter string 6: Alizeh<br>Enter string 7: haisam<br>The correct order for the strings is:<br>aleEm<br>Aleena<br>Alizeh<br>BismaH<br>HaiDer<br>haiSam<br>SALman<br>

Extracted text: Write a program that takes an integer input n from the user and then asks the user to enter n strings. All the n strings must contain just the English alphabets (may contain both capital and small letters). In case a user enters any other character for a particular string, the program should ask the user to enter that particular string again. After the user is done entering those n strings, the program should sort those all n strings alphabetically (considering only the first element of the string for sorting). Small alphabets have more precedence than capital alphabets, so small alphabets come first. Display the sorted output on the screen. Sample Program: Enter a value for n: 7 Enter string 1: HaiDer Enter string 2: BismaH Enter string 3: aleEm Enter string 4: Aleena Enter string 5: SALman Enter string 6: Alizeh Enter string 7: haisam The correct order for the strings is: aleEm Aleena Alizeh BismaH HaiDer haiSam SALman

Jun 10, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here