Author Topic: [C/C++] Joe vs Ergot: Code wars!  (Read 24175 times)

0 Members and 3 Guests are viewing this topic.

Offline MyndFyre

  • Boticulator Extraordinaire
  • x86
  • Hero Member
  • *****
  • Posts: 4540
  • The wait is over.
    • View Profile
    • JinxBot :: the evolution in boticulation
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #45 on: October 05, 2005, 08:03:51 pm »
GNU is the best. GNU rocks. <3 GNU. If I were lazy, this topic wouldn't exist. What C++ compiler should I aim to have this work with? M$VC? Right, well, I'll go pay a thousand dollars for software I use as a hobby. Wait.. The GNU C++ compiler is free. Bingo!

Or, maybe, if you actually coded correctly, it would work on either one, Mr. Cross-Platform Compatibility.

For example, this page talks about the differences between ISO C (C99) and ISO C++ (C++98).  Throughout the document, #include <iostream> is used; never once is #include <iostream.h>

Also, information about the ANSI C++ Standard specifically talks about header files (in order to support precompiled headers):
Quote
Header file names no longer maintain the .h extension typical of the C language and of pre-standard C++ compilers, as in the case of stdio.h, stdlib.h, iostream.h, etc. This extension h simply disappears and files previously known as iostream.h become iostream (without .h).

Also Joe, MSVC++ 2003 compiler and platform SDK are also free.

Logic defeats counter-culture *nix-ism again! G_G
« Last Edit: October 06, 2005, 01:44:48 am by MyndFyre[x86] »
I have a programming folder, and I have nothing of value there

Running with Code has a new home!

Our species really annoys me.

Offline drka

  • ffdshow > in_mp3.dll
  • Full Member
  • ***
  • Posts: 330
    • View Profile
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #46 on: October 06, 2005, 01:12:57 am »
haha i was about to say that the MSVC++ compiler is free.

btw:for those of you who dont know where to dl it, search google for Microsoft Visual C++ Toolkit 2003. im in love with it since it can compile managed code.

Offline MyndFyre

  • Boticulator Extraordinaire
  • x86
  • Hero Member
  • *****
  • Posts: 4540
  • The wait is over.
    • View Profile
    • JinxBot :: the evolution in boticulation
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #47 on: October 06, 2005, 01:44:25 am »
btw:for those of you who dont know where to dl it, search google for Microsoft Visual C++ Toolkit 2003. im in love with it since it can compile managed code.
Or: you could click the link that I provided above, "MSVC++ 2003 compiler and platform SDK".
I have a programming folder, and I have nothing of value there

Running with Code has a new home!

Our species really annoys me.

Offline Joe

  • B&
  • Moderator
  • Hero Member
  • *****
  • Posts: 10319
  • In Soviet Russia, text read you!
    • View Profile
    • Github
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #48 on: October 06, 2005, 06:58:45 pm »
And this topic is officially dead.
I'd personally do as Joe suggests

You might be right about that, Joe.


Offline rabbit

  • x86
  • Hero Member
  • *****
  • Posts: 8092
  • I speak for the entire clan (except Joe)
    • View Profile
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #49 on: October 06, 2005, 08:18:42 pm »
GNU is the best. GNU rocks. <3 GNU. If I were lazy, this topic wouldn't exist. What C++ compiler should I aim to have this work with? M$VC? Right, well, I'll go pay a thousand dollars for software I use as a hobby. Wait.. The GNU C++ compiler is free. Bingo!
My point was that if it doesn't work with the GNU compiler you obviously suck at life because the GNU compiler will compile any code that's valid.

Offline Joe

  • B&
  • Moderator
  • Hero Member
  • *****
  • Posts: 10319
  • In Soviet Russia, text read you!
    • View Profile
    • Github
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #50 on: October 06, 2005, 10:12:10 pm »
And the GNU compiler compiles my code, so theres nothing to worry about.
I'd personally do as Joe suggests

You might be right about that, Joe.


Offline drka

  • ffdshow > in_mp3.dll
  • Full Member
  • ***
  • Posts: 330
    • View Profile
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #51 on: October 07, 2005, 12:35:08 am »
btw:for those of you who dont know where to dl it, search google for Microsoft Visual C++ Toolkit 2003. im in love with it since it can compile managed code.
Or: you could click the link that I provided above, "MSVC++ 2003 compiler and platform SDK".
i didnt realize that it was a link :P. i can barely see any links with this skin

Offline AntiVirus

  • Legendary
  • x86
  • Hero Member
  • *****
  • Posts: 2521
  • Best
    • View Profile
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #52 on: October 07, 2005, 11:31:57 am »
Time for a new skin.. ^^;
The once grove of splendor,
Aforetime crowned by lilac and lily,
Lay now forevermore slender;
And all winds that liven
Silhouette a lone existence;
A leafless oak grasping at eternity.


"They say that I must learn to kill before I can feel safe, but I rather kill myself then turn into their slave."
- The Rasmus

Offline Joe

  • B&
  • Moderator
  • Hero Member
  • *****
  • Posts: 10319
  • In Soviet Russia, text read you!
    • View Profile
    • Github
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #53 on: October 15, 2005, 11:36:25 pm »
joe@JoeMomma:~/dev/cpp/ascii $ cat ./main.cpp
// Ascii Chart
// Author: Joe[e2]

#include <iostream>
using namespace std;

int main() {
  char character; int i2;
  for(int i=0x11; i<0x100; i=i+5) {
    for(i2=1; i2<6; i2++) {
      if(i2+i+1 >= 0x100) {
      } else {
        character = i2+i+1;
        cout << "0x" << hex << i2+i+1 << " == " << character << "   ";
      }
    }
    cout << endl;
  }
  return 0;
}


joe@JoeMomma:~/dev/cpp/ascii $ g++ -o main.o main.cpp && ./main.o
0x13 ==    0x14 ==    0x15 ==    0x16 ==    0x17 == 
0x18 ==    0x19 ==    0x1a ==    0x1b ==    0x1c == 
0x1d ==    0x1e ==    0x1f ==    0x20 ==     0x21 == !
0x22 == "   0x23 == #   0x24 == $   0x25 == %   0x26 == &
0x27 == '   0x28 == (   0x29 == )   0x2a == *   0x2b == +
0x2c == ,   0x2d == -   0x2e == .   0x2f == /   0x30 == 0
0x31 == 1   0x32 == 2   0x33 == 3   0x34 == 4   0x35 == 5
0x36 == 6   0x37 == 7   0x38 == 8   0x39 == 9   0x3a == :
0x3b == ;   0x3c == <   0x3d == =   0x3e == >   0x3f == ?
0x40 == @   0x41 == A   0x42 == B   0x43 == C   0x44 == D
0x45 == E   0x46 == F   0x47 == G   0x48 == H   0x49 == I
0x4a == J   0x4b == K   0x4c == L   0x4d == M   0x4e == N
0x4f == O   0x50 == P   0x51 == Q   0x52 == R   0x53 == S
0x54 == T   0x55 == U   0x56 == V   0x57 == W   0x58 == X
0x59 == Y   0x5a == Z   0x5b == [   0x5c == \   0x5d == ]
0x5e == ^   0x5f == _   0x60 == `   0x61 == a   0x62 == b
0x63 == c   0x64 == d   0x65 == e   0x66 == f   0x67 == g
0x68 == h   0x69 == i   0x6a == j   0x6b == k   0x6c == l
0x6d == m   0x6e == n   0x6f == o   0x70 == p   0x71 == q
0x72 == r   0x73 == s   0x74 == t   0x75 == u   0x76 == v
0x77 == w   0x78 == x   0x79 == y   0x7a == z   0x7b == {
0x7c == |   0x7d == }   0x7e == ~   0x7f ==    0x80 == &#128;
0x81 == ?   0x82 == &#130;   0x83 == &#131;   0x84 == &#132;   0x85 == &#133;
0x86 == &#134;   0x87 == &#135;   0x88 == &#136;   0x89 == &#137;   0x8a == &#138;
0x8b == &#139;   0x8c == &#140;   0x8d == ?   0x8e == &#142;   0x8f == ?
0x90 == ?   0x91 == &#145;   0x92 == &#146;   0x93 == &#147;   0x94 == &#148;
0x95 == &#149;   0x96 == &#150;   0x97 == &#151;   0x98 == &#152;   0x99 == &#153;
0x9a == &#154;   0x9b == &#155;   0x9c == &#156;   0x9d == ?   0x9e == &#158;
0x9f == &#159;   0xa0 ==     0xa1 == ¡   0xa2 == ¢   0xa3 == £
0xa4 == ¤   0xa5 == ¥   0xa6 == ¦   0xa7 == §   0xa8 == ¨
0xa9 == ©   0xaa == ª   0xab == «   0xac == ¬   0xad == ­
0xae == ®   0xaf == ¯   0xb0 == °   0xb1 == ±   0xb2 == ²
0xb3 == ³   0xb4 == ´   0xb5 == µ   0xb6 == ¶   0xb7 == ·
0xb8 == ¸   0xb9 == ¹   0xba == º   0xbb == »   0xbc == ¼
0xbd == ½   0xbe == ¾   0xbf == ¿   0xc0 == À   0xc1 == Á
0xc2 ==    0xc3 == à  0xc4 == Ä   0xc5 == Å   0xc6 == Æ
0xc7 == Ç   0xc8 == È   0xc9 == É   0xca == Ê   0xcb == Ë
0xcc == Ì   0xcd == Í   0xce == Π  0xcf == Ï   0xd0 == Ð
0xd1 == Ñ   0xd2 == Ò   0xd3 == Ó   0xd4 == Ô   0xd5 == Õ
0xd6 == Ö   0xd7 == ×   0xd8 == Ø   0xd9 == Ù   0xda == Ú
0xdb == Û   0xdc == Ü   0xdd == Ý   0xde == Þ   0xdf == ß
0xe0 == à   0xe1 == á   0xe2 == â   0xe3 == ã   0xe4 == ä
0xe5 == å   0xe6 == æ   0xe7 == ç   0xe8 == è   0xe9 == é
0xea == ê   0xeb == ë   0xec == ì   0xed == í   0xee == î
0xef == ï   0xf0 == ð   0xf1 == ñ   0xf2 == ò   0xf3 == ó
0xf4 == ô   0xf5 == õ   0xf6 == ö   0xf7 == ÷   0xf8 == ø
0xf9 == ù   0xfa == ú   0xfb == û   0xfc == ü   0xfd == ý
0xfe == þ   0xff == ÿ
« Last Edit: October 15, 2005, 11:37:57 pm by Joe[e2] »
I'd personally do as Joe suggests

You might be right about that, Joe.


Offline Joe

  • B&
  • Moderator
  • Hero Member
  • *****
  • Posts: 10319
  • In Soviet Russia, text read you!
    • View Profile
    • Github
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #54 on: October 16, 2005, 01:25:09 am »
I have created the UGLIEST loop ever. An array of 13 ints (which isn't even an array) in imbeded for statments, to create every single possible CD-Key. C++, or manual labor?

Ergot, beat this or go pump gas~.

joe@JoeMomma:~/dev/cpp/sckmg $ g++ -o SCKMG main.cpp && ./SCKMG
SCKMG by Joe[e2] loaded.
Valid key: 0000000000003
Valid key: 0000000000014
Valid key: 0000000000021
Valid key: 0000000000032
Valid key: 0000000000047
Valid key: 0000000000058
Valid key: 0000000000065
Valid key: 0000000000076
Valid key: 0000000000081
Valid key: 0000000000092
Valid key: 0000000000106
Valid key: 0000000000117
Valid key: 0000000000128
Valid key: 0000000000139
Valid key: 0000000000142
Valid key: 0000000000153
Valid key: 0000000000164
Valid key: 0000000000175
Valid key: 0000000000184
Valid key: 0000000000195
Valid key: 0000000000207
Valid key: 0000000000218
Valid key: 0000000000225
Valid key: 0000000000236
Valid key: 0000000000243
Valid key: 0000000000254
Valid key: 0000000000261
Valid key: 0000000000272
Valid key: 0000000000289
Valid key: 0000000000290
Valid key: 0000000000300
Valid key: 0000000000311
Valid key: 0000000000322
Valid key: 0000000000333
Valid key: 0000000000344
Valid key: 0000000000355
Valid key: 0000000000366
Valid key: 0000000000377
Valid key: 0000000000388
Valid key: 0000000000399
Valid key: 0000000000401
Valid key: 0000000000412
Valid key: 0000000000429
Valid key: 0000000000430
Valid key: 0000000000445
Valid key: 0000000000456
Valid key: 0000000000463
Valid key: 0000000000474
Valid key: 0000000000483
Valid key: 0000000000494
Valid key: 0000000000504
Valid key: 0000000000515
Valid key: 0000000000526
Valid key: 0000000000537
Valid key: 0000000000540
Valid key: 0000000000551
Valid key: 0000000000562
Valid key: 0000000000573
Valid key: 0000000000586
Valid key: 0000000000597
Valid key: 0000000000605
Valid key: 0000000000616
Valid key: 0000000000623
Valid key: 0000000000634
Valid key: 0000000000641
Valid key: 0000000000652
Valid key: 0000000000669
Valid key: 0000000000670
Valid key: 0000000000683
Valid key: 0000000000694
Valid key: 0000000000708
Valid key: 0000000000719
Valid key: 0000000000720
Valid key: 0000000000731
Valid key: 0000000000742
Valid key: 0000000000753
Valid key: 0000000000764
Valid key: 0000000000775
Valid key: 0000000000780
Valid key: 0000000000791
Valid key: 0000000000807
Valid key: 0000000000818
Valid key: 0000000000825
Valid key: 0000000000836
Valid key: 0000000000841
Valid key: 0000000000852
Valid key: 0000000000869
Valid key: 0000000000870
Valid key: 0000000000885
Valid key: 0000000000896
Valid key: 0000000000900
Valid key: 0000000000911
Valid key: 0000000000922
Valid key: 0000000000933
Valid key: 0000000000946
Valid key: 0000000000957
Valid key: 0000000000968
Valid key: 0000000000979
Valid key: 0000000000988
Valid key: 0000000000999
Valid key: 0000000001002
Valid key: 0000000001013
Valid key: 0000000001024
Valid key: 0000000001035
Valid key: 0000000001046
Valid key: 0000000001057
Valid key: 0000000001068
Valid key: 0000000001079
Valid key: 0000000001084
Valid key: 0000000001095
Valid key: 0000000001105
Valid key: 0000000001116
Valid key: 0000000001123
Valid key: 0000000001134
Valid key: 0000000001149
Valid key: 0000000001150
Valid key: 0000000001167
Valid key: 0000000001178
Valid key: 0000000001187
Valid key: 0000000001198
Valid key: 0000000001208
Valid key: 0000000001219
Valid key: 0000000001220
Valid key: 0000000001231
Valid key: 0000000001244
Valid key: 0000000001255
Valid key: 0000000001266
Valid key: 0000000001277
Valid key: 0000000001280
Valid key: 0000000001291
Valid key: 0000000001301
Valid key: 0000000001312
Valid key: 0000000001329
Valid key: 0000000001330
Valid key: 0000000001347
Valid key: 0000000001358
Valid key: 0000000001365
Valid key: 0000000001376
Valid key: 0000000001383
Valid key: 0000000001394
Valid key: 0000000001404
Valid key: 0000000001415
Valid key: 0000000001426
Valid key: 0000000001437
Valid key: 0000000001448
Valid key: 0000000001459
Valid key: 0000000001460
Valid key: 0000000001471
Valid key: 0000000001482
Valid key: 0000000001493
Valid key: 0000000001507
Valid key: 0000000001518
Valid key: 0000000001525
Valid key: 0000000001536
Valid key: 0000000001541
Valid key: 0000000001552
Valid key: 0000000001569
Valid key: 0000000001570
Valid key: 0000000001585


By the way, theres more valid keys out there. I just didn't want to make too big of a post.
I'd personally do as Joe suggests

You might be right about that, Joe.


Offline Newby

  • Moderator
  • Hero Member
  • *****
  • Posts: 10877
  • Thrash!
    • View Profile
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #55 on: October 16, 2005, 02:35:01 am »
if mingw cant compile managed code, then it sucks

Would you mind telling me the differences (technical) between managed code, and unmanaged code, since you seem to know so much about managed code and its benefits and why compilers should be able to compile it?
- Newby
http://www.x86labs.org

Quote
[17:32:45] * xar sets mode: -oooooooooo algorithm ban chris cipher newby stdio TehUser tnarongi|away vursed warz
[17:32:54] * xar sets mode: +o newby
[17:32:58] <xar> new rule
[17:33:02] <xar> me and newby rule all

I'd bet that you're currently bloated like a water ballon on a hot summer's day.

That analogy doesn't even make sense.  Why would a water balloon be especially bloated on a hot summer's day? For your sake, I hope there wasn't too much logic testing on your LSAT. 

Offline MyndFyre

  • Boticulator Extraordinaire
  • x86
  • Hero Member
  • *****
  • Posts: 4540
  • The wait is over.
    • View Profile
    • JinxBot :: the evolution in boticulation
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #56 on: October 16, 2005, 05:25:19 am »
if mingw cant compile managed code, then it sucks

Would you mind telling me the differences (technical) between managed code, and unmanaged code, since you seem to know so much about managed code and its benefits and why compilers should be able to compile it?
You're asking him to do it specifically, right?  I'm not allowed to?
I have a programming folder, and I have nothing of value there

Running with Code has a new home!

Our species really annoys me.

Offline Newby

  • Moderator
  • Hero Member
  • *****
  • Posts: 10877
  • Thrash!
    • View Profile
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #57 on: October 16, 2005, 01:07:37 pm »
You're asking him to do it specifically, right?  I'm not allowed to?

Nope! Mangix seems to be intelligent on the subject, and I am not, so I'd like to be enlightened as to how it works. :)
- Newby
http://www.x86labs.org

Quote
[17:32:45] * xar sets mode: -oooooooooo algorithm ban chris cipher newby stdio TehUser tnarongi|away vursed warz
[17:32:54] * xar sets mode: +o newby
[17:32:58] <xar> new rule
[17:33:02] <xar> me and newby rule all

I'd bet that you're currently bloated like a water ballon on a hot summer's day.

That analogy doesn't even make sense.  Why would a water balloon be especially bloated on a hot summer's day? For your sake, I hope there wasn't too much logic testing on your LSAT. 

Offline drka

  • ffdshow > in_mp3.dll
  • Full Member
  • ***
  • Posts: 330
    • View Profile
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #58 on: October 16, 2005, 02:01:18 pm »
if mingw cant compile managed code, then it sucks

Would you mind telling me the differences (technical) between managed code, and unmanaged code, since you seem to know so much about managed code and its benefits and why compilers should be able to compile it?
Managed code is just C++ with Managed Extensions or C++ .NET(even though Microsoft didnt do anything to the language(i think)).

Unmanaged code is regular code that doesnt use .NET Namespaces but instead uses functions and other stuff from #includes just like Joe has been doing

And the reason that i think all compilers should compile it is because even though it uses .NET, it's still C++(and you can write managed code with unmanaged code which is kinda fun)

Offline MyndFyre

  • Boticulator Extraordinaire
  • x86
  • Hero Member
  • *****
  • Posts: 4540
  • The wait is over.
    • View Profile
    • JinxBot :: the evolution in boticulation
Re: [C/C++] Joe vs Ergot: Code wars!
« Reply #59 on: October 17, 2005, 02:33:49 am »
That's one of the most incomplete responses EVER!
I have a programming folder, and I have nothing of value there

Running with Code has a new home!

Our species really annoys me.