Click to See Complete Forum and Search --> : Ascii?
Stephen Bazemore
Nov 19th, 2000, 08:41 PM
Ok, this is something a friend of mine gave me.
unsigned char MousesAsciiArt[187] = {
201,176,177,178,219,219,219,219,219,
176,177,178,219,219,219,219,219,176,
177,178,219,219,178,219,219,205,205,
187, 10,186, 32, 32,176,177,178,219,
32, 32,176,177,178,219,219,178,219,
219,176,177,178,219,219,178,219,219,
32, 32,186, 10,186, 32, 32,176,177,
178,219, 32, 32,176,177,178,219,219,
219,219,219,176,177,178,219,219,219,
219,219, 32, 32,186, 10,186, 32, 32,
176,177,178,219, 32, 32,176,177,178,
219,219,178,219,219,176,177,178,219,
219,178,219,219, 32, 32,186, 10,186,
32, 32,176,177,178,219, 32, 32,176,
177,178,219,219,219,219,219,176,177,
178,219,219,178,219,219, 32, 32,186,
10,200,205,205,205,205,205,205,205,
205,205,205,205,205,205,205,205,205,
205,205,205,205,205,205,205,205,205,
205,188, 10, 10, 201, 36, 45};
void main(){
FILE *TARGET_FILE;
unsigned long FILE_SIZE = 0;
int CurChar = 0;
char FILE_GUTS[TARGET_FILE_SIZE - 1];
while(CurChar <= 173){
printf("%c",MousesAsciiArt[CurChar]);
CurChar++;}
In that code, how can I find out what each number represents?
Any help is appreciated. Thanks.
Sam Finch
Nov 19th, 2000, 08:49 PM
the simplest way is to start a console app project, add
#include <iostream.h>
and then cout << MousesAsciiArt;
it'll print out whatever it is
(it's a little 3d thing the letters TBH with a border around it)
Stephen Bazemore
Nov 19th, 2000, 09:02 PM
Hmm.. that really doesn't help much by looking at that. Well it does kinda.. is there a chart or anything that shows what character each number equals? I've searched but havent found anything.
Vlatko
Nov 20th, 2000, 06:09 AM
As Sam Finch sad it is a figure(the letters TBH). Try this code:
[code]
#include <iostream.h>
int main(int argc, char* argv[])
{
unsigned char Ascii[187] = {
201,176,177,178,219,219,219,219,219,
176,177,178,219,219,219,219,219,176,
177,178,219,219,178,219,219,205,205,
187, 10,186, 32, 32,176,177,178,219,
32, 32,176,177,178,219,219,178,219,
219,176,177,178,219,219,178,219,219,
32, 32,186, 10,186, 32, 32,176,177,
178,219, 32, 32,176,177,178,219,219,
219,219,219,176,177,178,219,219,219,
219,219, 32, 32,186, 10,186, 32, 32,
176,177,178,219, 32, 32,176,177,178,
219,219,178,219,219,176,177,178,219,
219,178,219,219, 32, 32,186, 10,186,
32, 32,176,177,178,219, 32, 32,176,
177,178,219,219,219,219,219,176,177,
178,219,219,178,219,219, 32, 32,186,
10,200,205,205,205,205,205,205,205,
205,205,205,205,205,205,205,205,205,
205,205,205,205,205,205,205,205,205,
205,188, 10, 10, 201, 36, 45};
for(int c=0;i<188;i++)
cout<<Ascii[c];
return 0;
}
Stephen Bazemore
Nov 20th, 2000, 10:30 AM
I'm getting a compile error "i , undeclared identifier"
any ideas?
Sam Finch
Nov 20th, 2000, 10:35 AM
it's here
for(int c=0;i<188;i++)
should be
for(int c=0;c<188;c++)
Stephen Bazemore
Nov 20th, 2000, 10:37 AM
Nevermind I got it to compile.. but for some reason it only loops the first character on my screen. any help is appreciated.
Woby Tide
Nov 20th, 2000, 08:00 PM
If you simply want to know what each number represents open a dos window then press control-alt and type in the relevant ascii number. When you let go of all 3 keys the corresponding ascii symbol will appear. Hope this helps.
HarryW
Nov 20th, 2000, 08:53 PM
This code works fine for me. (Vlatko's code with errors corrected)
#include <iostream.h>
int main(int argc, char* argv[])
{
unsigned char Ascii[187] = {
201,176,177,178,219,219,219,219,219,
176,177,178,219,219,219,219,219,176,
177,178,219,219,178,219,219,205,205,
187, 10,186, 32, 32,176,177,178,219,
32, 32,176,177,178,219,219,178,219,
219,176,177,178,219,219,178,219,219,
32, 32,186, 10,186, 32, 32,176,177,
178,219, 32, 32,176,177,178,219,219,
219,219,219,176,177,178,219,219,219,
219,219, 32, 32,186, 10,186, 32, 32,
176,177,178,219, 32, 32,176,177,178,
219,219,178,219,219,176,177,178,219,
219,178,219,219, 32, 32,186, 10,186,
32, 32,176,177,178,219, 32, 32,176,
177,178,219,219,219,219,219,176,177,
178,219,219,178,219,219, 32, 32,186,
10,200,205,205,205,205,205,205,205,
205,205,205,205,205,205,205,205,205,
205,205,205,205,205,205,205,205,205,
205,188, 10, 10, 201, 36, 45};
for(int c=0;c<188;c++)
cout<<Ascii[c];
return 0;
}
(Hmm, looks like Vlatko forgot to close his code tag)
Vlatko
Nov 21st, 2000, 06:43 AM
Yes you are right i forgot to close the code tag. About the errors in the code. I first used cout<<Ascii[i] but that was making everything italic(as you can see now haha) and that is why i changed i to c but forgot to change every apperance of c. Never mind that the code works.
parksie
Nov 21st, 2000, 02:14 PM
Maybe we could get John to disable things like that in tags.
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.