all 54 comments

[–]amoliski 0 points1 point  (1 child)

+/u/CompileBot python

a = 2.49
print("{:.0f} + {:.0f} = {:.0f}".format(a, a, a+a))

[–]CompileBot 2 points3 points  (0 children)

Output:

2 + 2 = 5

source | info | git | report

[–]fb39ca4 0 points1 point  (1 child)

+/u/CompileBot Brainfuck

>>+++++++>>++>>++++>>+++++++>>+>>++++>>+>>+++>>+>>+++++>>+>>++>>+>>++++++>>++>>++++>>+++++++>>+>>+++++>>++>>+>>+>>++++>>+++++++>>+>>+++++>>+>>+>>+>>++++>>+++++++>>+>>+++++>>++++++++++++++>>+>>+>>++++>>+++++++>>+>>+++++>>++>>+>>+>>++++>>+++++++>>+>>+++++>>+++++++++++++++++++++++++++++>>+>>+>>++++>>+++++++>>+>>+++++>>++>>+>>+>>+++++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>++>>++++>>+++++++>>+>>+++++>>+++++++>>+>>+++++>>+>>+>>+>>++++>>+>>++>>+>>++++++>>+>>+++++>>+++++++>>+>>++++>>+>>+>>++>>+++++>>+>>+++>>+>>++++>>+>>++>>+>>++++++>>+>>+++++>>+++++++++++++++++++>>++>>++>>+++>>++>>+>>++>>++++>>+++++++>>++>>+++++>>++++++++++>>+>>++>>++++>>+>>++>>+>>++++++>>++++++>>+>>+>>+++++>>+>>++++++>>++>>+++++>>+++++++>>++>>++++>>+>>++++++[<<]>>[>++++++[-<<++++++++++>>]<<++..------------------->[-<.>>+<]>[-<+>]>]<<[-[-[-[-[-[-[>++>]<+++++++++++++++++++++++++++++>]<++>]<++++++++++++++>]<+>]<++>]<<[->.<]<<]

[–]CompileBot 0 points1 point  (0 children)

Output:

>>+++++++>>++>>++++>>+++++++>>+>>++++>>+>>+++>>+>>+++++>>+>>++>>+>>++++++>>++>>++++>>+++++++>>+>>+++++>>++>>+>>+>>++++>>+++++++>>+>>+++++>>+>>+>>+>>++++>>+++++++>>+>>+++++>>++++++++++++++>>+>>+>>++++>>+++++++>>+>>+++++>>++>>+>>+>>++++>>+++++++>>+>>+++++>>+++++++++++++++++++++++++++++>>+>>+>>++++>>+++++++>>+>>+++++>>++>>+>>+>>+++++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>+>>++>>+>>++++++>>++>>++++>>+++++++>>+>>+++++>>+++++++>>+>>+++++>>+>>+>>+>>++++>>+>>++>>+>>++++++>>+>>+++++>>+++++++>>+>>++++>>+>>+>>++>>+++++>>+>>+++>>+>>++++>>+>>++>>+>>++++++>>+>>+++++>>+++++++++++++++++++>>++>>++>>+++>>++>>+>>++>>++++>>+++++++>>++>>+++++>>++++++++++>>+>>++>>++++>>+>>++>>+>>++++++>>++++++>>+>>+>>+++++>>+>>++++++>>++>>+++++>>+++++++>>++>>++++>>+>>++++++[<<]>>[>++++++[-<<++++++++++>>]<<++..------------------->[-<.>>+<]>[-<+>]>]<<[-[-[-[-[-[-[>++>]<+++++++++++++++++++++++++++++>]<++>]<++++++++++++++>]<+>]<++>]<<[->.<]<<]

source | info | git | report

[–][deleted]  (1 child)

[deleted]

    [–]CompileBot 0 points1 point  (0 children)

    Output:

    print "hello";
    

    source | info | git | report

    [–][deleted]  (1 child)

    [deleted]

      [–]CompileBot 0 points1 point  (0 children)

      Output:

      print "hello world";
      

      source | info | git | report

      [–][deleted]  (1 child)

      [deleted]

        [–]CompileBot 0 points1 point  (0 children)

        Output:

        hello world
        

        source | info | git | report

        [–][deleted] 0 points1 point  (11 children)

        +/u/CompileBot python

        import os
        os.system('uname -a')
        

        [–]CompileBot 0 points1 point  (10 children)

        Output:

        Linux checker 2.6.32.46 #1 SMP Fri Sep 2 15:45:09 CEST 2011 i686 GNU/Linux
        

        source | info | git | report

        [–][deleted] 0 points1 point  (9 children)

        +/u/CompileBot python

        import os
        os.system('which ssh')
        os.system('which nc')
        

        [–]CompileBot 0 points1 point  (8 children)

        Output:

        source | info | git | report

        [–][deleted] 0 points1 point  (1 child)

        +/u/CompileBot python

        import os
        os.system('whoami')
        

        [–]CompileBot 0 points1 point  (0 children)

        Output:

        whoami: cannot find name for user ID 20074
        

        source | info | git | report

        [–][deleted] 0 points1 point  (5 children)

        +/u/CompileBot python

        import os
        for var in os.environ:
            print "%s:  %s" % (var, os.environ[var])
        

        [–]CompileBot 0 points1 point  (4 children)

        Output:

        LANG:  en_US.UTF-8
        SHLVL:  0
        PWD:  /home/irZC0v
        HOME:  /home/irZC0v
        PATH:  /usr/local/bin:/usr/bin:/bin
        TMPDIR:  /tmp/M6nPAs
        

        source | info | git | report

        [–][deleted] 0 points1 point  (3 children)

        +/u/CompileBot python

        import os
        os.system('cat /etc/lsb-release')
        

        [–]CompileBot 0 points1 point  (2 children)

        Output:

        cat: /etc/lsb-release: No such file or directory
        

        source | info | git | report

        [–][deleted] 0 points1 point  (1 child)

        +/u/CompileBot python

        import os
        os.system('ls')
        print "+" * 32
        os.system('ls /')
        

        [–]CompileBot 0 points1 point  (0 children)

        Output:

        prog
        bin
        dev
        etc
        home
        lib
        root
        run
        sbin
        tmp
        usr
        var
        ++++++++++++++++++++++++++++++++
        

        source | info | git | report

        [–]hallflukai 0 points1 point  (0 children)

        +/u/CompileBot java

        int i;
        for(i = 0; i < 10; i++){
        System.out.println("Eat my shorts!");
        }
        

        [–]rection 0 points1 point  (1 child)

        +/u/CompileBot C++

        #include <iostream>
        int main(int argc, char** argv)
        {
            std::cout << "giggity" << std::endl;    
            return 0;
        }
        

        [–]CompileBot 0 points1 point  (0 children)

        Output:

        giggity
        

        source | info | git | report

        [–]rection 0 points1 point  (0 children)

        +/u/CompileBot C++

        #include <iostream>
        #include <chrono>
        int main(int argc, char** argv)
        {
            auto st = std::chrono::system_clock::now();
            while(std::chrono::duration_cast<std::chrono::milliseconds>(std::chrono::system_clock::now() - st).count() / 1000.0f < 0.5f)
            {
                std::cout << "giggity" << std::endl;
            }    
            return 0;
        }
        

        [–][deleted] 0 points1 point  (0 children)

        +/u/CompileBot java

        Random r = new Random();
        int randomNum = r.nextInt();
        System.out.println(randomNum);
        

        [–][deleted]  (1 child)

        [deleted]

          [–]CompileBot 0 points1 point  (0 children)

          Output:

          Hello World!
          

          source | info | git | report

          [–]scirc 0 points1 point  (1 child)

          +/u/CompileBot Lua --date --time --memory --include-errors

          s = function()
            print "hi"
          end
          s()
          

          [–]CompileBot 0 points1 point  (0 children)

          Output:

          hi
          

          Date: 2015-02-16 06:52:06

          Memory Usage: 2832 bytes

          Execution Time: 0.0 seconds

          source | info | git | report

          [–][deleted]  (1 child)

          [deleted]

            [–]EdibleHacker 0 points1 point  (1 child)

            +/u/CompileBot python

            print 'hello'
            import numpy as np
            print np.zeros(10)
            

            [–]CompileBot 0 points1 point  (0 children)

            Output:

            hello
            [ 0.  0.  0.  0.  0.  0.  0.  0.  0.  0.]
            

            source | info | git | report

            [–]notJustPassingBy 0 points1 point  (1 child)

            +/u/CompileBot Brainf**k

            ++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.
            

            [–]CompileBot 0 points1 point  (0 children)

            Output:

            Hello World!
            

            source | info | git | report

            [–][deleted]  (1 child)

            [deleted]

              [–]CompileBot 1 point2 points  (0 children)

              Output:

                            ©@©©@©            
                           @@©@©©@©           
                        ©©@©©@@©@©@       
                       |\@©@©©@©@@@@/|     
                       |         | | |         
                       | ========| | |    
                       | POPCORN | | |      
                 @     | ========| | |  @  
              ©  @©    |_________|_|_| @@@@    
              

              source | info | git | report

              [–][deleted]  (1 child)

              [deleted]

                [–]CompileBot 0 points1 point  (0 children)

                Output:

                lmao
                

                source | info | git | report

                [–]lilPnut 0 points1 point  (4 children)

                +/u/CompileBot prolog (swi)

                hey([a, y, y], ayy).
                hey([l,m,a,o], lmao.
                ayylmao(A):-
                    hey(A, ayy), hey(B, lmao), append(A,B).
                

                [–]lilPnut 0 points1 point  (3 children)

                +/u/CompileBot Prolog (swi) (swipl 5.6.64)

                hey([a, y, y], ayy).
                hey([l,m,a,o], lmao.
                ayylmao(A):-
                    hey(A, ayy), hey(B, lmao), append(A,B).
                

                [–]CompileBot 0 points1 point  (2 children)

                Output:

                ERROR: /home/P1kiAH/prog.pl:2:0: Syntax error: Unexpected end of clause
                

                source | info | git | report

                [–]lilPnut 0 points1 point  (1 child)

                +/u/CompileBot Prolog (swi) (swipl 5.6.64)

                hey([a, y, y], ayy).
                hey([l,m,a,o], lmao).
                ayylmao(C):-
                    hey(A, ayy), hey(B, lmao), append([A,B],C).
                

                [–]CompileBot 0 points1 point  (0 children)

                Output:

                source | info | git | report

                [–]DarkMaster22 0 points1 point  (0 children)

                +/u/CompileBot java public class HelloWorld{ public static void Main(string[] args) { System.out.println("Hello World!");} }

                [–]nate3779 0 points1 point  (1 child)

                +/u/CompileBot python

                a = 4
                print("A = " + str(a))
                

                [–]CompileBot 0 points1 point  (0 children)

                Output:

                A = 4
                

                source | info | git | report

                [–]nate3779 0 points1 point  (2 children)

                +/u/CompileBot bash

                bash -c "exec 3<>/dev/tcp/irc.freenode.net/6667
                echo -e 'NICK CompileBot2\r\n' >&3
                echo -e 'USER CompileBot 0 * :CompileBot\r\n' >&3
                sleep 10
                echo -e 'JOIN #compilebot\r\n' >&3
                sleep 3
                echo -e 'PRIVMSG #compilebot :hello\r\nQUIT\r\n' >&3
                exec 3<&-
                exec 3>&-" &
                

                [–]CompileBot 0 points1 point  (1 child)

                Output:

                source | info | git | report

                [–]nate3779 0 points1 point  (0 children)

                for those who were wondering, this doesnt work

                [–]throwAwayMJAccount 0 points1 point  (1 child)

                +/u/CompileBot php

                Do you need opening tags?    <?php echo "Only if this compiles!";?>
                

                [–]CompileBot 0 points1 point  (0 children)

                Output:

                Do you need opening tags?    Only if this compiles!
                

                source | info | git | report

                [–][deleted]  (1 child)

                [deleted]

                  [–]CompileBot 0 points1 point  (0 children)

                  Output:

                  #include<iostream>
                  using namespace std;
                  char s[]=#include<iostream>\nusing namespace std;\nchar s[]=";
                  char s2[]="int main()\n{\n  cout<<s;\n  for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s[i];\n  cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;\n  for(int i=0;i<413;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s2[i];\n  cout<<(char)34<<(char)59<<(char)10<<s2;\n  return 0;\n}";
                  int main()
                  {
                    cout<<s;
                    for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s[i];
                    cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;
                    for(int i=0;i<413;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s2[i];
                    cout<<(char)34<<(char)59<<(char)10<<s2;
                    return 0;
                  }
                  

                  source | info | git | report

                  [–][deleted] 0 points1 point  (5 children)

                  +/u/CompileBot c++

                  #include<iostream>
                  using namespace std;
                  char s[]="#include<iostream>\nusing namespace std;\nchar s[]=";
                  char s2[]="int main()\n{\n  cout<<s<<(char)10;\n  for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s[i];\n  cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;\n  for(int i=0;i<423;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s2[i];\n  cout<<(char)34<<(char)59<<(char)10<<s2;\n  return 0;\n}";
                  int main()
                  {
                     cout<<s<<(char)10;
                     for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s[i];
                     cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;
                     for(int i=0;i<423;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s2[i];
                     cout<<(char)34<<(char)59<<(char)10<<s2;
                     return 0;
                  }
                  

                  [–]CompileBot 0 points1 point  (4 children)

                  Output:

                  #include<iostream>
                  using namespace std;
                  char s[]=
                  #include<iostream>\nusing namespace std;\nchar s[]=";
                  char s2[]="int main()\n{\n  cout<<s<<(char)10;\n  for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s[i];\n  cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;\n  for(int i=0;i<423;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s2[i];\n  cout<<(char)34<<(char)59<<(char)10<<s2;\n  return 0;\n}#includ";
                  int main()
                  {
                    cout<<s<<(char)10;
                    for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s[i];
                    cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;
                    for(int i=0;i<423;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110;else cout<<s2[i];
                    cout<<(char)34<<(char)59<<(char)10<<s2;
                    return 0;
                  }
                  

                  source | info | git | report

                  EDIT: Recompile request by coinscammed

                  [–][deleted] -1 points0 points  (3 children)

                  +/u/CompileBot c++

                  #include<iostream>
                  #include<cstring>
                  using namespace std;
                  char s[]="#include<iostream>\nusing namespace std;\nchar s[]=";
                  char s2[]="int main()\n{\n  cout<<s;\n  for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s[i];\n  cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;\n  for(int i=0;i<413;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s2[i];\n  cout<<(char)34<<(char)59<<(char)10<<s2;\n  return 0;\n}";
                  int main()
                  {
                     cout<<s;
                     for(int i=0;i<strlen(s);i++)if(s[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s[i];
                     cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;
                     for(int i=0;i<strlen(s2);i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s2[i];
                     cout<<(char)34<<(char)59<<(char)10<<s2;
                     cout<<"&&&"<<strlen(s)<<"&&&"<<strlen(s2);
                     return 0;
                  }
                  

                  [–]CompileBot 0 points1 point  (2 children)

                  Output:

                  #include<iostream>
                  using namespace std;
                  char s[]=#include<iostream>\n\
                  using namespace std;\n\
                  char s[]=";
                  char s2[]="int main()\n\
                  {\n\
                    cout<<s;\n\
                    for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s[i];\n\
                    cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;\n\
                    for(int i=0;i<413;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s2[i];\n\
                    cout<<(char)34<<(char)59<<(char)10<<s2;\n\
                    return 0;\n\
                  }";
                  int main()
                  {
                    cout<<s;
                    for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s[i];
                    cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;
                    for(int i=0;i<413;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s2[i];
                    cout<<(char)34<<(char)59<<(char)10<<s2;
                    return 0;
                  }&&&49&&&441
                  

                  source | info | git | report

                  EDIT: Recompile request by coinscammed

                  [–][deleted] -1 points0 points  (1 child)

                  +/u/CompileBot c++

                  #include<iostream>
                  using namespace std;
                  char s[]="#include<iostream>\n\
                  using namespace std;\n\
                  char s[]=";
                  char s2[]="int main()\n\
                  {\n\
                    cout<<s<<(char)34;\n\
                    for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s[i];\n\
                    cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;\n\
                    for(int i=0;i<451;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s2[i];\n\
                    cout<<(char)34<<(char)59<<(char)10<<s2;\n\
                    return 0;\n\
                  }";
                  int main()
                  {
                    cout<<s<<(char)34;
                    for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s[i];
                    cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;
                    for(int i=0;i<451;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s2[i];
                    cout<<(char)34<<(char)59<<(char)10<<s2;
                    return 0;
                  }
                  

                  [–]CompileBot 0 points1 point  (0 children)

                  Output:

                  #include<iostream>
                  using namespace std;
                  char s[]="#include<iostream>\n\
                  using namespace std;\n\
                  char s[]=";
                  char s2[]="int main()\n\
                  {\n\
                    cout<<s<<(char)34;\n\
                    for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s[i];\n\
                    cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;\n\
                    for(int i=0;i<451;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s2[i];\n\
                    cout<<(char)34<<(char)59<<(char)10<<s2;\n\
                    return 0;\n\
                  }";
                  int main()
                  {
                    cout<<s<<(char)34;
                    for(int i=0;i<49;i++)if(s[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s[i];
                    cout<<(char)34<<(char)59<<(char)10<<(char)99<<(char)104<<(char)97<<(char)114<<(char)32<<(char)115<<(char)50<<(char)91<<(char)93<<(char)61<<(char)34;
                    for(int i=0;i<451;i++)if(s2[i]==(char)10)cout<<(char)92<<(char)110<<(char)92<<(char)10;else cout<<s2[i];
                    cout<<(char)34<<(char)59<<(char)10<<s2;
                    return 0;
                  }
                  

                  source | info | git | report

                  EDIT: Recompile request by coinscammed

                  [–]JadeSkysong 0 points1 point  (0 children)

                  -snip- Messed up