This video, kindly made by Chris Roffey from Bebras UK, nicely demonstrates how to use the code editor/grader on this site:


All inputs should be read from standard in and outputs printed to standard out.

Students are permitted to have available up to 20 sides of custom notes/snippets (paper or digital) in addition to the  standard documentation for their chosen language during the competition. One such example for python is this document, adapted with permission from Coding-Club Core Cards.

These examples all read a single integer and print double that number out.

num = int(input())
print(num * 2)
import java.io.*;
import java.util.*;

public class Solution {
public static void main(String[] args) {
    // Enter your code here
    Scanner scanner = new Scanner(System.in);
int num = scanner.nextInt();
System.out.println(num * 2);

using System;
using System.Collections.Generic;
using System.IO;

class Solution {
static void Main(String[] args) {
// Enter your code here
int num = Int32.Parse(Console.ReadLine());
Console.WriteLine(num * 2);


Module Solution
Sub Main()
' Enter your code here
Dim num As Integer = Integer.Parse(Console.ReadLine())
Console.WriteLine(num * 2)
End Sub
End Module

JavaScript (Node.js)
var stdin = "";
var stdin_arr;
var prompt = () => stdin_arr.pop();
process.stdin.on('data', (data) => {stdin += data});
process.stdin.on('end', () => {stdin_arr = stdin.split("\n");stdin_arr.reverse();main()});

function main() {
// Enter your code here
  var num = parseInt(prompt());
    console.log(num * 2);

C++ 11:

#include <cmath>
#include <cstdio>
#include <vector>
#include <iostream>
#include <algorithm>
using namespace std;

int main() {
// Enter your code here
string sNum;
getline(cin, sNum);
int num = stoi(sNum);
cout << num * 2 << "\n";
return 0;

Note: one advantage of using getline for c++ input is that when multiple values are provided on one line of input (e.g. 2 3 5 7) then you can easily read through to the next delimeter e.g.

getline(cin, sNum, ' ');

However, of course, you could also in this case just do the shorter:

#include <iostream>
using namespace std;

int main() {
  // Enter your code here
  int num;
  cin >> num;
  cout << num * 2 << "\n";
  return 0;