I have some sentences that I want to print out the first character of each sentence. when I print it out I get the first character many times. here is the code. I just want the first character of each sentence printed out once per line.

int i;
int j;

	for (i = 0; i < FIindex; i++)
	{
	    for (j = 0; j < FJindex; j++)
	   {
	        std::cout << fragments[i][0] << " " << std::endl;
	    }
		
                }

delete the j loop

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.