Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Fool

  • 27-07-2000 4:08pm
    #1
    Closed Accounts Posts: 218 ✭✭


    #include <stdio.h>
    #define p(x) \
    printf("%c", \
    f(x++)));}
    #define f(x) arr[x]
    #define s(x) int \
    main(x){
    #define R(y,z) (y>>z)
    #define L(w,x) \
    (w<<x)\

    s(void) int i,arr[14]={ 'M',
    'r',
    '.',
    ' ',
    'T',
    ' ',
    'S',
    'a',
    'y',
    's',
    ';'};f(4)=f(8)=f(3);f(13)=R((f(0)=(R(f(2),1))+(R(f(1),1)
    )),3);f(2)=f(5)=f(1)+2;f(1+(L(1,1)))=((L(1,7))-7);f(10)=f(10+R((0xA&0xB),3))
    =(f(2)-(1+(L(1,2))));f(7)=((f(9)=(f(6)=(f(1)=0x069)-1)-2)-1);f((L(2,2)+(L(1,2)
    )))=(0xFD&0x16E);for(i=0;i<14;p


Comments

  • Moderators, Social & Fun Moderators Posts: 28,633 Mod ✭✭✭✭Shiminay


    I think you should have put UBB "code" tags around that...
    #include &lt;stdio.h&gt;
    #define p(x) \
    printf("%c", \
    f(x++)));}
    #define f(x) arr[x]
    #define s(x) int \
    main(x){
    #define R(y,z) (y&gt;&gt;z)
    #define L(w,x) \
    (w&lt;&lt;x)\
    
    s(void) int i,arr[14]={ 'M',
    'r',
    '.',
    ' ',
    'T',
    ' ',
    'S',
    'a',
    'y',
    's',
    ';'};
    f(4)=f(8)=f(3);f(13)=R((f(0)=(R(f(2),1))+(R(f(1),1)
    )),3);
    f(2)=f(5)=f(1)+2;f(1+(L(1,1)))=((L(1,7))-7);
    f(10)=f(10+R((0xA&0xB),3))=(f(2)-(1+(L(1,2))));
    f(7)=((f(9)=(f(6)=(f(1)=0x069)-1)-2)-1);
    f((L(2,2)+(L(1,2))))=(0xFD&0x16E);
    
    for(i=0; i&lt;14 ;p
    

    Like so smile.gif

    All the best,

    Dav
    @B^)
    My page of stuff

    [This message has been edited by Kharn (edited 28-07-2000).]


  • Registered Users, Registered Users 2 Posts: 6,265 ✭✭✭MiCr0


    someone put up the output


  • Moderators, Social & Fun Moderators Posts: 10,501 Mod ✭✭✭✭ecksor


    Originally posted by MiCr0:
    someone put up the output

    I would, but it didn't compile for me.


  • Registered Users, Registered Users 2 Posts: 16,414 ✭✭✭✭Trojan


    I would, but it didn't compile for me.

    Same as that. FYI:
    Compiling D:\TC\PCANTEST.C:
    Error D:\TC\PCANTEST.C 25: Undefined symbol 'p' in function main
    Error D:\TC\PCANTEST.C 25: For statement missing ) in function main
    Error D:\TC\PCANTEST.C 26: Compound statement missing } in function main
    Warning D:\TC\PCANTEST.C 26: Function should return a value in function main
    

    Al.

    --

    amdsoft.com


  • Closed Accounts Posts: 411 ✭✭Jay


    Lads, I think he's taking the **** with that 'code'.

    What is it 'supposed' to do anyway?



  • Advertisement
  • Moderators, Social & Fun Moderators Posts: 10,501 Mod ✭✭✭✭ecksor


    Originally posted by Jay:
    Lads, I think he's taking the **** with that 'code'.

    What is it 'supposed' to do anyway?

    Ok, I took a go at it (I am a closet C ninja wink.gif ) and figured out that there are only a couple of characters missing off the end.
    So, here it is ...
    #include &lt;stdio.h&gt;
    #define p(x) \
    printf("%c", \
    f(x++)));}
    #define f(x) arr[x]
    #define s(x) int \
    main(x){
    #define R(y,z) (y&gt;&gt;z)
    #define L(w,x) \
    (w&lt;&lt;x)\
    
    s(void) int i,arr[14]={ 'M',
    'r',
    '.',
    ' ',
    'T',
    ' ',
    'S',
    'a',
    'y',
    's',
    ';'};f(4)=f(8)=f(3);f(13)=R((f(0)=(R(f(2),1))+(R(f(1),1)
    )),3);f(2)=f(5)=f(1)+2;f(1+(L(1,1)))=((L(1,7))-7);f(10)=f(10+R((0xA&0xB),3))
    =(f(2)-(1+(L(1,2))));f(7)=((f(9)=(f(6)=(f(1)=0x069)-1)-2)-1);f((L(2,2)+(L(1,2)
    )))=(0xFD&0x16E);for(i=0;i&lt;14;p(i)
    


  • Registered Users, Registered Users 2 Posts: 16,414 ✭✭✭✭Trojan


    Lads, I think he's taking the **** with that 'code'.
    What is it 'supposed' to do anyway?

    Nah, the whole point is that the code is supposed to be obfuscated, check out IOCCC (if it's up, seem s to be down atm). The idea is to try and figure what it does before you run it... good luck, but I don't have that much time on my hands... smile.gif

    Al.



  • Closed Accounts Posts: 6,601 ✭✭✭Kali


    pah obfuscated c ..
    perl is the king of it smile.gif


  • Closed Accounts Posts: 411 ✭✭Jay


    blup

    [This message has been edited by Jay (edited 02-08-2000).]


  • Closed Accounts Posts: 411 ✭✭Jay


    Correct code
    #include &lt;stdio.h&gt;
    
    #define p(x) printf("%c", f(x++)));}
    
    #define f(x) arr[x]
    
    #define s(x) int main(x){
    
    #define R(y,z) (y&gt;&gt;z)
    
    #define L(w,x) (w&lt;&lt;x) 
    
    s(void) int i,arr[14]={ 'M','r','.',' ','T',' ','S','a','y','s',';'};
    
    f(4)=f(8)=f(3);
    f(13)=R((f(0)=(R(f(2),1))+(R(f(1),1))),3);
    
    f(2)=f(5)=f(1)+2;
    f(1+(L(1,1)))=((L(1,7))-7);
    
    f(10)=f(10+R((0xA&0xB),3))=(f(2)-(1+(L(1,2))));
    
    f(7)=((f(9)=(f(6)=(f(1)=0x069)-1)-2)-1);
    
    f((L(2,2)+(L(1,2))))=(0xFD&0x16E);
    
    for(i=0; i&lt;14 ;p(i)
    

    Output:

    Pity the fool


  • Advertisement
  • Closed Accounts Posts: 411 ✭✭Jay


    Balls, sure I didnt even notice X_OR's post, he has the correct code there already.

    X_OR - you L33T Ninja C programmer.


Advertisement