Code: Select all
////////////////////////////////////////
// By: Peter Marsh (Nebuchadnazzar)
// for: ccb056
// 09/27/03
////////////////////////////////////////
#include <stdio.h>
#include <string.h>
#include <ctype.h>
#include <math.h>
#include <stdlib.h>
#include <time.h>
void exita();
//File names
#define asciiFile "asciiFile.f"
//Files
FILE *fp1;
//Constants
void main( void )
{
int i, j, k, h, p, x, g, t;
char asciiString[8];
fp1 = fopen("asciiFile.f", "wb");
//For the following you could make for(_ = 70; _< 75 ; _++) for a 3+- mb file
//to see the result open the asciiFile.f in notepad.
//if you run the thing the way it is it will slow you comp like MAD (ctrl-alt-del style)
//and create a file over 100MB (too large for notepad) in seconds
for(i = 0; i< 128 ; i++)
for(j = 0; j< 128 ; j++)
for(k = 0; k< 128 ; k++)
for(h = 0; h< 128 ; h++)
for(p = 0; p< 128 ; p++)
for(x = 0; x< 128 ; x++)
for(g = 0; g< 128 ; g++)
for(t = 0; t< 128 ; t++)
{
asciiString[0] = (char)i;
asciiString[1] = (char)j;
asciiString[2] = (char)k;
asciiString[3] = (char)h;
asciiString[4] = (char)p;
asciiString[5] = (char)x;
asciiString[6] = (char)g;
asciiString[7] = (char)t;
fwrite(&asciiString, sizeof(asciiString), 1, fp1);
}
fclose(fp1);
}