🔒 Closed Pa help po pls using string po

Status
Not open for further replies.
wag dito sa fb pages ka humingi nang tulong mas responsive dun tsaka gawa ka muna draft bago mag pa tulong dito may service din ako sa fiverr pero mahal.
 
C++:
#include <iostream>
#include <string>
using namespace std;

int main()
{
    string input;
    char vowels[5] = { 'A', 'E', 'I', 'O', 'U' };
    char jeje[5] = {'@','^','!','*','$'};

    cout << "Input name: ";
    getline (cin, input);

    for(int i=0;i<input.length(); i++)
    {
        char c = toupper(input[i]);
        for (int j = 0; j < 5; j++)
        {
            if (c==vowels[j])
            {
                input[i] = jeje[j];
            }
        }
    }

    cout << "Encrypted name: " << input;

    return 0;
}

not sure kung gagana
 
Status
Not open for further replies.

Similar threads

About this Thread

  • 3
    Replies
  • 418
    Views
  • 2
    Participants
Last reply from:
Iaminkwo

Trending Topics

Online now

Members online
997
Guests online
3,410
Total visitors
4,407

Forum statistics

Threads
2,299,264
Posts
29,128,888
Members
1,201,891
Latest member
championdigong
Back
Top