How to arrange the number properly?

Two dimensional array


ifstream infile("STA83EXM.txt");

void main()
	const int row = 140;
	const int column = 140;
	int matrix[row] [column];

//**************creates Matrix****************
	int num;
		for(int i = 0; i<=row-1; i++)
			for(int j = 0; j<=column-1; j++)
//***************Prints out Matrix*********************
{	cout << "i,j"<<"\t";
	for(int i = 1; i < 140; i++)
	for(int j= 1; j < 140; j++)
		cout<<j<< "\n";


How to arrange the number properly?

One digit after another. If there is a portion that's below 1, add a '.' and that portion. If negative, '-' in front of all the digits.

How to arrange the number properly?

Congrats: Taking this and other threads into account, you've just scored an A+ in "The art of asking vague questions"!

Perhaps you mean sorting a list a numbers? If so:bubblesort

Edited 6 Years Ago by Nick Evan: n/a

the number is 1 until 139

no number below 1 and negative.

OK, then I update my quote with this new information:

One digit after another.

This article has been dead for over six months. Start a new discussion instead.