Result:
EXECUTE
Result
Option
EXECUTE
Execution existed!
String str Hello
Result:
Length of string 5
String str
Option
Result
Hello
Length of string 5
Otherwise, make the request b.
b. Execute: (1.5 point)
- If users choose "Length of string" option, count the number of characters of the string str, then add the result to table as shown below.
- If users choose "Consonant characters" option, count the number of characters that are consonants in string str, then add the result to table as shown below.
=>
(Consonants are defined as any letter in the English alphabet that is not a vowel (a, e, i, o, u). The count should be case-insensitive and exclude any non-alphabetic characters)
When input string and choose an option
After clicking the "EXECUTE" button
Zoom
Close
+ 100%