Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

SHOW ME YOUR QUINES

Name: Anonymous 2010-07-06 19:36


const char *s[15] = {
        "%c%c%s%c%c%c",
        "const char *s[15] = {",
        "};",
        "#include <stdio.h>",  
        "int main(void) {",
        "        int i;",
        "        puts(s[1]);",
        "        for (i=0; i<14; ++i)",
        "                printf(s[0], 9, 34, s[i], 34, 44, 10);",
        "        printf(s[0], 9, 34, s[i], 34, 0, 10);",
        "        puts(s[2]);",
        "        for (i=3; i<15; ++i)",
        "                puts(s[i]);",
        "        return 0;",
        "}"
};
#include <stdio.h>
int main(void) {
        int i;
        puts(s[1]);
        for (i=0; i<14; ++i)
                printf(s[0], 9, 34, s[i], 34, 44, 10);
        printf(s[0], 9, 34, s[i], 34, 0, 10);
        puts(s[2]);
        for (i=3; i<15; ++i)
                puts(s[i]);
        return 0;
}

the one I wrote.

Name: Oh we're on quines now? 2010-07-06 19:53

10 LIST

Name: Anonymous 2010-07-06 20:26

super(this)

Name: Anonymous 2010-07-06 20:29

How long before some retard tries something inane like `cat $0`?
Oh wait >>2 already did it.

Look, quines don't read their own program file as input. That's not a quine, that's just a program that reads itself.

Name: Anonymous 2010-07-06 20:31

>>4
I argued that with the residents of esolang. I lost.

Name: Anonymous 2010-07-06 20:33

>>5
Let's have sex

Name: Anonymous 2010-07-06 20:35

>>6
Sure. But not both at the same time.

Name: Anonymous 2010-07-06 21:14

infile = open(__file__, 'r')
for line in infile:
    print line,


Expert python implementation.

Name: Anonymous 2010-07-06 21:19

#!/bin/cat

Name: Anonymous 2010-07-06 21:39

Name: Anonymous 2010-07-06 22:07

>>10
if >>9 isn't a quine, then it's impossible to write a quine in any interpreted language.

Name: Anonymous 2010-07-06 22:11

>>11
There are arguments against >>9,8,4 that aren't applicable to >>2. My stance on these is "cares little."

Name: Anonymous 2010-07-06 22:20

>>4
Technically a queue is a program that outputs it's own source code.  Nothing specifically says it can't read it's own source as a file.  These types of programs are still queues.

Name: Anonymous 2010-07-06 22:37

>>13
That's not what a ``queue'' is, otherwise I don't feel like disagreeing with you.

Name: 2010-07-06 22:40

Name: 2010-07-06 22:42

Name: Anonymous 2010-07-06 22:53

>>14
I know, it can be tiresome being a pedantic asshole.

Name: Anonymous 2010-07-06 22:54

>>17
Do tell us all about it.

Name: Anonymous 2010-07-06 23:06

print "print"

Name: Anonymous 2010-07-07 0:38

>>19
Well this one certainly doesn't qualify.

Name: Anonymous 2010-07-07 1:07

>>19
$ cat >quine.pl
print "print"
$ perl quine.pl > output.txt

$ diff -y quine.pl output.txt
print "print"                              |    print
$

Name: Anonymous 2010-07-07 2:15

>>12
Did u mena:
There are arguments against >>2,8,4 that aren't applicable to >>9.

Name: Anonymous 2010-07-07 3:26

>>21
you are doing it wrong.
but nice try.

Name: Anonymous 2010-07-07 3:34

________________________________
( Man what is with this >>23 guy )
 --------------------------------
        o   ^__^
         o  (oo)\_______
            (__)\       )\/\
                ||----w |
                ||     ||

Name: Anonymous 2010-07-07 9:08

>>22
No. In case I have to spell it out, >>2 doesn't read its source file as a part of the algorithm contained within the source file. The others do.

Name: Anonymous 2010-07-07 9:53

In HQ9+:

Q

Name: Anonymous 2010-07-07 9:57

>>25
>>9 doesn't either.

Name: Anonymous 2010-07-07 10:03

Here's one:

Interpreter is cat.

Name: Anonymous 2010-07-07 10:08

Name: Anonymous 2010-07-07 10:13

>>29
>>9 doesn't output itself.

Name: 2394 2010-07-07 10:13

test

Name: 2394 2010-07-07 10:13

test

Name: 2394 2010-07-07 10:13

test

Name: Anonymous 2010-07-08 3:40

>>30

/bin/bash
cat $0

Name: Anonymous 2010-08-16 21:02

I just wrote a 356 byte ELF quine and just had to revive this thread.

>>> import os
>>> os.popen("./quine").read() == open("quine").read()
True
>>> open("quine").read().encode("hex")
'7f454c4601010100000000000000000002000300010000008080040834000000c40000000000000034002000020028000400030001000000000000000080040800800408a8000000a8000000050000000010000001000000a8000000a8900408a890040802000000020000000600000000100000000000000000000000000000b9a890040881e9a8000000ba64010000b804000000bb01000000cd80b801000000bb00000000cd800000002e7368737472746162002e74657874002e6461746100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000b000000010000000600000080800408800000002800000000000000000000001000000000000000110000000100000003000000a8900408a8000000020000000000000000000000040000000000000001000000030000000000000000000000aa0000001700000000000000000000000100000000000000'

Name: Anonymous 2010-08-16 21:03

That's

7f454c4601010100000000000000000002000300010000008080040834000000c
40000000000000034002000020028000400030001000000000000000080040800
800408a8000000a8000000050000000010000001000000a8000000a8900408a89
0040802000000020000000600000000100000000000000000000000000000b9a8
90040881e9a8000000ba64010000b804000000bb01000000cd80b801000000bb0
0000000cd800000002e7368737472746162002e74657874002e64617461000000
00000000000000000000000000000000000000000000000000000000000000000
000000000000000000b0000000100000006000000808004088000000028000000
00000000000000001000000000000000110000000100000003000000a8900408a
80000000200000000000000000000000400000000000000010000000300000000
00000000000000aa0000001700000000000000000000000100000000000000

Name: Anonymous 2010-08-16 21:19

Here's the first quine I ever wrote. Not very short, but it works.

char* e(char*s){char*r,*e;r=e=malloc(strlen(s)*2);while(*s){if(*s=='"'||*s=='\\')*(e++)='\\';*(e++)=*(s++);}*e=0;return r;}int main(){char*c="char* e(char*s){char*r,*e;r=e=malloc(strlen(s)*2);while(*s){if(*s=='\"'||*s=='\\\\')*(e++)='\\\\';*(e++)=*(s++);}*e=0;return r;}int main(){char*c=\"%s\";char*s=e(c);printf(c,s);free(s);return 0;}";char*s=e(c);printf(c,s);free(s);return 0;}

$ ./a.out | diff - quine.c
$

Name: Anonymous 2010-08-16 21:59

I realize that Python is easymodo, but
x='x=%s;print x%%repr(x)';print x%repr(x)

Name: Anonymous 2010-08-17 0:49

>>35
You broke Shiichan.

Name: Anonymous 2010-08-17 2:43

>>39
broke YOUR ANUS

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List