View Single Post
Old 10-25-2004, 02:04 AM   #2 (permalink)
redhead
Newbie
 
redhead's Avatar
 
Join Date: Jun 2002
Location: Denmark
Posts: 1,735
redhead is on a distinguished road
are you looking for something like this:
Code:
#include <iostream>
using namespace std;

int main (void)
{
  cout << "ASCII Table times 3" << endl;
  int i,n;
  const int array = 256*3;
  char arr[array];

  for(i=0; i<array; i++)
   arr[i] = i%256;
  for(n=0; n<3; n++)
  {
    for(i=0; i<256; i++)
     cout << (char) arr[i];
    cout << endl << endl;
  }
  return 0;
}
__________________
Don't worry Ma'am, We're university students, We know what We're doing.
-----
If you pull the pin, Mr.Grenade would no longer be your friend.
-----
01000111 01101111 00100000 01000011 00100000 00100001
redhead is offline   Reply With Quote