Looking for an inspiration? Below you will find public programs submitted by other users.

Filter by: Bash C C# C++ 5.1 C++14 Haskell Java Java7 Objective-C Pascal (fpc) Pascal (gpc) Perl PHP Python Python 3 Ruby SQL VB.NET more...

#gRXY9k C++14 1 second ago
Compilation
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int x,y,a=0,l,i,j;
  6. cin>>x>>y;
  7. char c[y][x];
  8. for( i=0;i<y;i++)
  9. {for( j=0;j<x;j++)
#xNsuou Pascal (fpc) 3 seconds ago
Running
  1. function Trova(N, K: longint; var A: array of longint): longint;
  2.  
  3. var M,i,j,c,max:longint;
  4. B:array[1..100000] of boolean;
  5.  
  6. begin
  7. if K=1 then M:=0;
  8. if K>N then M:=N
  9. else
#OxIw23 PHP 4 seconds ago
Runtime error
  1. <?php
  2. $myString = “Hello, world!; echo substr( $myString, 0, 5 ) .< br/ >; // Displays ‘Hello’ echo substr( $myString, 7 ) . “ < br/ > ”; // Displays ‘world!’ echo substr( $myString, -1 ) . “ < br/ > ”; // Displays ‘!’ echo substr( $myString, -5, -1 ) . “ < br/ > ”; // Displays ‘orld’
  3. You can ’ t modify characters within strings using substr() . If you need to change characters within a string, use substr_replace() instead. This function is described later in the chapter.
  4. // your code goes here
  5. ?>
#SC4oAB C++14 5 seconds ago
Success
  1. #include <iostream>
  2. using namespace std;
  3. int main ()
  4. {
  5. float p=0;
  6. int a[]={2,3,4,8,9,7,8,5};
  7. for (int i = 0; i<8; i++)
  8. {
  9. if (a[i]%2 !=0)
#7JOClp Python (Pypy) 23 seconds ago
Runtime error
  1. if None:
  2. print “check once”
#I6gAGg C++14 29 seconds ago
Runtime error
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int x,y,a=0,l,i,j;
  6. cin>>x>>y;
  7. char c[y][x];
  8. for( i=0;i<y;i++)
  9. {for( j=0;j<x;j++)
#x0JODV C++ 30 seconds ago
Compilation error
  1.  
  2.  
  3. #include <iostream>
  4. #
  5. #include <vector>
  6. using namespace std;
  7.  
  8. int SearchPosition(vector<int>&, int,int);
#dvxi2F C++14 35 seconds ago
Compilation error
  1. #include <iostream.h>
  2. int main ()
  3. {
  4. float p=0;
  5. int a[]={2,3,4,8,9,7,8,5};
  6. for (int i = 0; i<8; i++)
  7. {
  8. if (a[i]%2 !=0)
  9. {
#1s9R7g C++14 7 seconds ago
Success
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. void Primes(int a){
  5. for (int i=2; i<a; i++){
  6. bool prime = true;
  7. for (int j=2; j*j<=i;j++){
  8. if (i%j==0){
  9. prime = false;
#VRShit Python 41 seconds ago
Success
  1. F=lambda n:n and n-M(F(n-1))or 1
  2. M=lambda n:n and n-F(M(n-1))
  3. n=range(input())
  4. print map(F,n),'\n',map(M,n)
#sS83L7 Java 36 seconds ago
Compilation error
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. class WildcardError {
  8.  
  9. void foo(List<?> i) {
#dpORej Java 45 seconds ago
Compilation error
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. public class Ideone
  9. {
#E4ugR2 Python (Pypy) 50 seconds ago
Runtime error
  1. listaArestas = list()
  2. listaNodos = list()
  3. listaClausulas = list()
  4.  
  5. def reducao():
  6. leitura()
  7. adicionaNodos()
  8. criaGadgets()
#iuvjqw C 54 seconds ago
Success
  1. /* Histogram of Frequency of Different Characters in Input */
  2.  
  3. #include<stdio.h>
  4. #define TNOCHAR 128 /* Total Number of characters is 128: 0 - 127 */
  5.  
  6. int main(void)
  7. {
  8. int c,i,j;
#gs3fNh C 1 minute ago
Success
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. // your code goes here
  5. return 0;
  6. }
#UtavjR Java 1 minute ago
Compilation error
  1. import java.awt.*;
  2. import javax.swing.*;
  3. import java.awt.Graphics;
  4. public class Art extends JApplet {
  5. Color black = Color.black;
  6. Color blue = Color.blue;
  7. Color gray = Color.gray;
  8. Color red = Color.red;
  9. Color yellow = Color.yellow;
#uNIydQ Assembler 36 seconds ago
Compilation error
  1. data segment ; сегмент данных
  2. message db 'Hello, world!$' ; определение строки текста,
  3. ; символ '$' - признак конца
  4. ; печати при выводе на экран
  5. data ends
  6. stk segment stack ; сегмент стека
  7. db 256 dup (?) ; отводим место под стек
  8. stk ends
  9. code segment ; сегмент кода
#zmulms Java 1 minute ago
Success
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {
#YRyoP0 Python (Pypy) 1 minute ago
Runtime error
  1. listaArestas = list()
  2. listaNodos = list()
  3. listaClausulas = list()
  4.  
  5. def reducao():
  6. leitura()
  7. adicionaNodos()
  8. criaGadgets()
#Kdttvo C++14 1 minute ago
Compilation error
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main()
  5. {
  6. setlocale (LC_ALL, "RUSSIAN");
  7. float a, b, c;
  8. cout « "Введите значения сторон: /n Сторона А = "; cin » a;
  9. cout « "/n Сторона B = ";
#qWDQzG C++14 43 seconds ago
Success
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int a[11111], b[11111];
  5.  
  6. int main() {
  7. int t;
  8. cin >> t;
  9. while (t --> 0) {
#jIzTho Java 1 minute ago
Runtime error
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {
#TOC69A Python 1 minute ago
Success
  1. a= 1000+90*8
  2. print a
#yRR5TL Python 1 minute ago
Runtime error
  1. # Python27
  2. #Tuples being immutable it good
  3. my_tuple = range[1:24]
  4. print my_tuple
#1YLM5I Java 1 minute ago
Runtime error
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {
#dlC8xH C++14 1 minute ago
Success
  1. #include <iostream>
  2. using namespace std;
  3. int main()
  4. {
  5. int n=7, max;
  6. int a [ ]={45,78,458,4,56,89,2};
  7. max=a[0];
  8. for (int i=0;i<7;i++)
  9. if(a[i]%6==0 && a[i]>max)
#MPSMeJ Pascal (fpc) 1 minute ago
Success
  1. function Trova(N, K: longint; var A: array of longint): longint;
  2.  
  3. var M,i,j,c,max:longint;
  4. B:array[1..100000] of boolean;
  5.  
  6. begin
  7. if K=1 then M:=0;
  8. if K>N then M:=N
  9. else
#H3WIDc C++14 1 minute ago
Success
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. // your code goes here
  6. return 0;
  7. }
#rlWJiq Java 1 minute ago
Compilation error
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {
#6L7iWu Java 1 minute ago
Compilation error
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {