1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
|
#include <iostream>
using std::cin;
using std::cout;
using std::endl;
int main()
{
cout << "\n\n\nPRINTING CONTENTS OF ARRAY USING THE MOD Option" << endl
<< "====================================" << endl;
char* modpstr[] = { "A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"};
int modnumber = 0;
for(i = 0; modpstr[ i ]; i++)
{
cout << "Even Numbered Element = " << modnumber << " Contents of Element within Array is = " << modpstr[i++]<< endl;
}
system("PAUSE");
return 0;
}
|