+ 1
How to code a simple program in c or cpp language using string to print this👇(see in description)
Input-:pulkit soni Output-:p.soni
2 Respostas
+ 1
For c++, look up how to use substring.
For C, you will need to manipulate the character array yourself. Find the position of the space -> add a period after first letter -> add space after that? -> loop through last part of character array and place those letters after the space in order. Don't forget to null terminate!
+ 1
You can maybe split the string at the spaces, then get the first item's first character, and give it a dot