String Initials in C++
Monday, November 7, 2011
#include "iostream.h"
#include "conio.h"
using namespace std;
int main(void)
{
string f,m,l;
//string testing..getting the initials
cout<<"ENTER YOUR FULL NAME (first middle and lastname)";
cin>>f>>m>>l;
string initals = f.substr(0,1)
+ m.substr(0,1) + l.substr(0,1);
cout<<"Your initials are: "<
Sharing is so Easy: |
Labels:
C++,
Programming