This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

How to use MSVC++ random in gcc 3.2.2?


Hello,

I think that this may be the last question for a couple of weeks...

What should I do to utilize teaching material using references to random?

This is from Lawerneceville Press for grade 11 introductory programming using MSC++ v6. I'm trying to move all of our computers to Linux, and I'm finding small probelms such as iostream vs iostream.h ... Maybe random will be the last of my problems for this simple progamming.

<snip>

#include <iostream.h>
#include <conio.h>
#include <lvp\random.h>

int main()
{
	randomize();
	cout << "Doodler!  Press I/J/K/M to move, Q to quit" << endl;
	char KeyPressed;				// Key pressed by user
	int x=40;						// Establish initial position of cursor
	int y=10;
	char Character = '*';		// Initial char that is displayed
	do {
		// Plot a "point"
		gotoxy(x, y);
		cout << Character;
		gotoxy(x, y);				// Move blinking cursor under current spot


<snip>


Thank you,

Jim

_________________________________________________________________
Add photos to your e-mail with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]