wildest_alpha
| wildest_alpha | |
|---|---|
| Turn-in directory | 08_wildest_alpha/ |
| Files to turn in | wildest_alpha.c |
| Allowed functions | putchar |
- Write a program which displays the alphabet starting from the character in variable
start_char, followed by a newline. Use the following rules:- If the starting character is lowercase, display the alphabet in the
a -> zdirection. If the starting character is uppercase, display the alphabet in theZ -> Adirection. - Do not display these characters:
'F', 'P', 'Z', 'd', 'n', 'x' - Replace these characters with the corresponding number:
'a' && 'A' ->4, 'e' && 'E' ->3, 'i' && 'I' ->1, 'o' && 'O' ->0`` - The first and last character are displayed in uppercase, all others are displayed in lowercase. Except where other rules apply.
- The character
'u'is always displayed uppercase. - When there is nothing to display, we still expect the newline.
- If the starting character is lowercase, display the alphabet in the
- Your programs needs to have a variable called
start_char, by default it will hold the character'c'. Changing this value changes the output of your program. The value can be set to any lower or uppercase letter. - Your programs needs to have a variable called
stop_char, by default it will hold the character'x'. Changing this value changes the output of your program. The value can be set to any lowercase letter.
Example output:
$ ./a.out
C3fgh1jklm0pqrstUvwy
$