Write a function char_to_int that accepts a character string and returns a vector of integers, one for each character in the string. The integer value should be 1 through 26, reflecting the position...



Write a function char_to_int that accepts a character string and returns a vector


of integers, one for each character in the string. The integer value should be 1


through 26, reflecting the position in the alphabet if the character is either an uppercase or lowercase letter; the value should be zero, otherwise. For example,


char_to_int("e") = [5] and char_to_int("a-z") = [1 0 26].



May 26, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here