// Remove vowels from a string
// Date 23:54 12/10/2016
// By Ben a.k.a DreamVB

#include <iostream>

using namespace std;
using std::cout;
using std::endl;

int main(int argc, char *argv[]){
	char s0[100], s1[100];
	char *vmap = "aeiou";
	int i = 0;
	int j = 0;
	
	strcpy(s0, "This Is A test to remove vowels from a string");

	while (i < strlen(s0)){
		//Check for vowel in the string
		if (strchr(vmap, tolower(s0[i])) == 0){
			//Build the new string with out vowels
			s1[j] = s0[i];
			//INC Counter
			j++;
		}
		//INC Counter
		i++;
	}
	//Add ending char
	s1[j] = '\0';

	//Print out
	cout << "Source     : " << s0 << endl;
	cout << "New String : " << s1 << endl;

	system("pause");
	return 0;
}