Someone
public text v1 · immutable
#include <iostream>
#include <fstream>
using namespace std;
#include <string>
//Create Function
void countWords(int count);
void countCharacters(int charNum);
int main()
{
int count = 0;
countWords(count);
int charNum = 0;
countCharacters(charNum);
return 0;
}
void countWords(int count)
{
string temp;
ifstream countWords( "txtdata.txt" );
while( countWords >> temp )
{
count = count + 1;
}
cout << "found " << count << " words" << endl;
}