/********************************************************************************\
 *										*
 *	Author:		Jeff Baron						*
 *										*
 *	Date:		09/09/02						*
 *										*
 *	Purpose:	Write a program to print a block E using astrisks (*)	*
 *			7 high, 5 wide						* 
 *										*
\********************************************************************************/

#include <iostream>
#include <math.h>
using namespace std;

void printE(const int howHigh, const int howWide);

int main(){
	
	printE(7,5);

	return (0);
}

/************************************ printE ************************************\

	Description:	Prints the E Block using *

	Parameters:	high: How high the block is
			wide: How wide the block is

	Returns:	Nothing

\********************************************************************************/
void printE(const int howHigh, const int howWide){
	int OuterCounter;
	int InnerCounter;
	int printWidth;

	for(InnerCounter = 0; InnerCounter < howHigh; InnerCounter++){
		if( (InnerCounter == 0) || (InnerCounter == ceil((howHigh/2)) ) || (InnerCounter == howHigh-1) ){
			for(printWidth = 0; printWidth < howWide; printWidth++)
				cout << "*";
				cout << endl;
		}
			else
			cout << "*" << endl; // end ifelse
	} 
}

/*
Example output using 7 high, 5 wide:

*****
*
*
*****
*
*
*****

*/
