malteklaes's picture
upload whole little cpp dataset
b263752 verified
raw
history blame
3.27 kB
{"repo": "ownRepo", "path": "cppExample.cpp", "func_name": "include", "original_string": "#include <iostream>\n", "code_tokens":["#include", "<iostream>"], "docstring_tokens": [], "sha": "[random sha]", "url": "noURL", "partition": "train"}
{"repo": "ownRepo", "path": "cppExample.cpp", "func_name": "addition", "original_string": "int addition(int a, int b) {\n return a + b;\n}\n", "code_tokens":["int", "addition", "(", "int", "a", ",", "int", "b", ")", "{", "return", "a", "+", "b", ";", "}"], "docstring_tokens": [], "sha": "[random sha]", "url": "noURL", "partition": "train"}
{"repo": "ownRepo", "path": "cppExample.cpp", "func_name": "subtraction", "original_string": "int subtraction(int a, int b) {\n return a - b;\n}\n", "code_tokens":["int", "subtraction", "(", "int", "a", ",", "int", "b", ")", "{", "return", "a", "-", "b", ";", "}"], "docstring_tokens": [], "sha": "[random sha]", "url": "noURL", "partition": "train"}
{"repo": "ownRepo", "path": "cppExample.cpp", "func_name": "multiplication", "original_string": "int multiplication(int a, int b) {\n return a * b;\n}\n", "code_tokens":["int", "multiplication", "(", "int", "a", ",", "int", "b", ")", "{", "return", "a", "*", "b", ";", "}"], "docstring_tokens": [], "sha": "[random sha]", "url": "noURL", "partition": "train"}
{"repo": "ownRepo", "path": "cppExample.cpp", "func_name": "division", "original_string": "float division(int a, int b) {\n if (b == 0) {\n std::cerr << \"Fehler: Division durch Null!\" << std::endl;\n return 0; // Oder eine geeignete Fehlerbehandlung\n }\n return static_cast<float>(a) / b;\n}\n", "code_tokens":["float", "division", "(", "int", "a", ",", "int", "b", ")", "{", "if", "(", "b", "==", "0", ")", "{", "std", "::", "cerr", "<<", "\"Fehler", ":", "Division", "durch", "Null", "!", "\"", "<<", "std", "::", "endl", ";", "return", "0", ";", "}", "return", "static_cast<float>", "(", "a", ")", "/", "b", ";", "}"], "docstring_tokens": [], "sha": "[random sha]", "url": "noURL", "partition": "train"}
{"repo": "ownRepo", "path": "cppExample.cpp", "func_name": "main", "original_string": "int main() {\n int x = 10;\n int y = 5;\n\n // Aufrufen der Funktionen und Ausgabe der Ergebnisse\n std::cout << \"Addition: \" << addition(x, y) << std::endl;\n std::cout << \"Subtraktion: \" << subtraction(x, y) << std::endl;\n std::cout << \"Multiplikation: \" << multiplication(x, y) << std::endl;\n std::cout << \"Division: \" << division(x, y) << std::endl;\n\n return 0;\n}\n", "code_tokens":["int", "main", "(", ")", "{", "int", "x", "=", "10", ";", "int", "y", "=", "5", ";", "std", "::", "cout", "<<", "\"Addition", ":", "\"", "<<", "addition", "(", "x", ",", "y", ")", "<<", "std", "::", "endl", ";", "std", "::", "cout", "<<", "\"Subtraktion", ":", "\"", "<<", "subtraction", "(", "x", ",", "y", ")", "<<", "std", "::", "endl", ";", "std", "::", "cout", "<<", "\"Multiplikation", ":", "\"", "<<", "multiplication", "(", "x", ",", "y", ")", "<<", "std", "::", "endl", ";", "std", "::", "cout", "<<", "\"Division", ":", "\"", "<<", "division", "(", "x", ",", "y", ")", "<<", "std", "::", "endl", ";", "return", "0", ";", "}"], "docstring_tokens": [], "sha": "[random sha]", "url": "noURL", "partition": "train"}