Hi, i am currently trying to write a program that can read 4 input characters (ie what a user selects) and then convert the character into its ASCII decimal number. I then need the sum of these characters eg if AAAA was inputted (65+65+65+65) then the output should show 260.
Atm the this is what i have:
i know i'll probably need some kind of array to indetify the other 3 characters, but where im new to the language, i was wondering if anyone knows some solutionsCode:#include <stdio.h> int main( void ) { char input_letter; input_letter = getchar(); printf("%d", input_letter ) ; }
Grant Searle.