Create data.jsonl
Browse files- data.jsonl +101 -0
data.jsonl
ADDED
|
@@ -0,0 +1,101 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{"messages":[{"role":"user","content":"I want to check if a Python set contains a specific element."},{"role":"assistant","content":"element in my_set"}]}
|
| 2 |
+
|
| 3 |
+
{"messages":[{"role":"user","content":"Show me how to create an empty list in Python."},{"role":"assistant","content":"my_list = []"}]}
|
| 4 |
+
|
| 5 |
+
{"messages":[{"role":"user","content":"I need a JavaScript example for adding an item to an array."},{"role":"assistant","content":"arr.push(item);"}]}
|
| 6 |
+
|
| 7 |
+
{"messages":[{"role":"user","content":"How can I find the minimum value in a JavaScript array?"},{"role":"assistant","content":"Math.min(...arr)"}]}
|
| 8 |
+
|
| 9 |
+
{"messages":[{"role":"user","content":"I want a Python example that checks if a number is greater than zero."},{"role":"assistant","content":"n > 0"}]}
|
| 10 |
+
|
| 11 |
+
{"messages":[{"role":"user","content":"Show me how to convert an integer to a string in Python."},{"role":"assistant","content":"str(n)"}]}
|
| 12 |
+
|
| 13 |
+
{"messages":[{"role":"user","content":"I need a Rust example for printing a variable to the console."},{"role":"assistant","content":"println!(\"{}\", value);"}]}
|
| 14 |
+
|
| 15 |
+
{"messages":[{"role":"user","content":"Show me how to remove an item from a Python set."},{"role":"assistant","content":"my_set.remove(value)"}]}
|
| 16 |
+
|
| 17 |
+
{"messages":[{"role":"user","content":"I want a SQL query that selects rows where a column is not null."},{"role":"assistant","content":"SELECT * FROM table_name WHERE column_name IS NOT NULL;"}]}
|
| 18 |
+
|
| 19 |
+
{"messages":[{"role":"user","content":"Show me how to find the length of a dictionary in Python."},{"role":"assistant","content":"len(my_dict)"}]}
|
| 20 |
+
|
| 21 |
+
{"messages":[{"role":"user","content":"I need a Go example for creating an empty slice."},{"role":"assistant","content":"var arr []int"}]}
|
| 22 |
+
|
| 23 |
+
{"messages":[{"role":"user","content":"Show me how to check if a string contains a substring in Python."},{"role":"assistant","content":"substring in s"}]}
|
| 24 |
+
|
| 25 |
+
{"messages":[{"role":"user","content":"I want a Java example for converting a string to uppercase."},{"role":"assistant","content":"s.toUpperCase();"}]}
|
| 26 |
+
|
| 27 |
+
{"messages":[{"role":"user","content":"Show me how to calculate the square root in Python."},{"role":"assistant","content":"import math\nmath.sqrt(x)"}]}
|
| 28 |
+
|
| 29 |
+
{"messages":[{"role":"user","content":"I need a JavaScript function that returns the square of a number."},{"role":"assistant","content":"const square = x => x * x;"}]}
|
| 30 |
+
|
| 31 |
+
{"messages":[{"role":"user","content":"Show me how to iterate through a dictionary in Python."},{"role":"assistant","content":"for k, v in my_dict.items():\n print(k, v)"}]}
|
| 32 |
+
|
| 33 |
+
{"messages":[{"role":"user","content":"I want a C++ example for checking if a number is positive."},{"role":"assistant","content":"if (n > 0) {\n cout << \"positive\";\n}"}]}
|
| 34 |
+
|
| 35 |
+
{"messages":[{"role":"user","content":"Show me how to convert a string to lowercase in JavaScript."},{"role":"assistant","content":"str.toLowerCase()"}]}
|
| 36 |
+
|
| 37 |
+
{"messages":[{"role":"user","content":"I need a Python example that checks if a list is empty."},{"role":"assistant","content":"len(my_list) == 0"}]}
|
| 38 |
+
|
| 39 |
+
{"messages":[{"role":"user","content":"Show me how to append multiple values to a list in Python."},{"role":"assistant","content":"my_list.extend([1,2,3])"}]}
|
| 40 |
+
|
| 41 |
+
{"messages":[{"role":"user","content":"I want a Go example for checking if a slice contains an element."},{"role":"assistant","content":"for _, v := range arr {\n if v == target {\n return true\n }\n}"}]}
|
| 42 |
+
|
| 43 |
+
{"messages":[{"role":"user","content":"Show me how to create a tuple in Python."},{"role":"assistant","content":"my_tuple = (1, 2, 3)"}]}
|
| 44 |
+
|
| 45 |
+
{"messages":[{"role":"user","content":"I need a Java example for comparing two strings."},{"role":"assistant","content":"s1.equals(s2)"}]}
|
| 46 |
+
|
| 47 |
+
{"messages":[{"role":"user","content":"Show me how to generate a random float in Python."},{"role":"assistant","content":"import random\nrandom.random()"}]}
|
| 48 |
+
|
| 49 |
+
{"messages":[{"role":"user","content":"I want a Rust example for checking if an option is None."},{"role":"assistant","content":"if option.is_none() {\n println!(\"None value\");\n}"}]}
|
| 50 |
+
|
| 51 |
+
{"messages":[{"role":"user","content":"Show me how to replace a substring in Python."},{"role":"assistant","content":"s.replace(\"old\", \"new\")"}]}
|
| 52 |
+
|
| 53 |
+
{"messages":[{"role":"user","content":"I need a SQL query that updates a column value."},{"role":"assistant","content":"UPDATE table_name SET column_name = value WHERE condition;"}]}
|
| 54 |
+
|
| 55 |
+
{"messages":[{"role":"user","content":"Show me how to check if a number is odd in Python."},{"role":"assistant","content":"n % 2 != 0"}]}
|
| 56 |
+
|
| 57 |
+
{"messages":[{"role":"user","content":"I want a JavaScript example for reversing an array."},{"role":"assistant","content":"arr.reverse()"}]}
|
| 58 |
+
|
| 59 |
+
{"messages":[{"role":"user","content":"Show me how to calculate exponentiation in Python."},{"role":"assistant","content":"pow(a, b)"}]}
|
| 60 |
+
|
| 61 |
+
{"messages":[{"role":"user","content":"I need a Go example for formatting strings."},{"role":"assistant","content":"fmt.Sprintf(\"Hello %s\", name)"}]}
|
| 62 |
+
|
| 63 |
+
{"messages":[{"role":"user","content":"Show me how to create a dictionary with default values in Python."},{"role":"assistant","content":"from collections import defaultdict\nd = defaultdict(int)"}]}
|
| 64 |
+
|
| 65 |
+
{"messages":[{"role":"user","content":"I want a C# example for checking if a list contains an item."},{"role":"assistant","content":"list.Contains(item)"}]}
|
| 66 |
+
|
| 67 |
+
{"messages":[{"role":"user","content":"Show me how to remove duplicates from a list in Python."},{"role":"assistant","content":"list(set(my_list))"}]}
|
| 68 |
+
|
| 69 |
+
{"messages":[{"role":"user","content":"I need a Java example for parsing integers."},{"role":"assistant","content":"int n = Integer.parseInt(str);"}]}
|
| 70 |
+
|
| 71 |
+
{"messages":[{"role":"user","content":"Show me how to check if a string is numeric in Python."},{"role":"assistant","content":"s.isdigit()"}]}
|
| 72 |
+
|
| 73 |
+
{"messages":[{"role":"user","content":"I want a Rust example for iterating over a vector."},{"role":"assistant","content":"for v in vec {\n println!(\"{}\", v);\n}"}]}
|
| 74 |
+
|
| 75 |
+
{"messages":[{"role":"user","content":"Show me how to join strings in JavaScript."},{"role":"assistant","content":"[\"a\",\"b\"].join(\"\")"}]}
|
| 76 |
+
|
| 77 |
+
{"messages":[{"role":"user","content":"I need a SQL query that deletes a row by id."},{"role":"assistant","content":"DELETE FROM table_name WHERE id = 1;"}]}
|
| 78 |
+
|
| 79 |
+
{"messages":[{"role":"user","content":"Show me how to check if a list contains duplicates in Python."},{"role":"assistant","content":"len(my_list) != len(set(my_list))"}]}
|
| 80 |
+
|
| 81 |
+
{"messages":[{"role":"user","content":"I want a Go example for converting int to string."},{"role":"assistant","content":"strconv.Itoa(n)"}]}
|
| 82 |
+
|
| 83 |
+
{"messages":[{"role":"user","content":"Show me how to split a string in Python."},{"role":"assistant","content":"s.split(\" \")"}]}
|
| 84 |
+
|
| 85 |
+
{"messages":[{"role":"user","content":"I need a JavaScript example for checking truthy values."},{"role":"assistant","content":"if (value) {\n console.log(\"truthy\");\n}"}]}
|
| 86 |
+
|
| 87 |
+
{"messages":[{"role":"user","content":"Show me how to calculate factorial recursively in Python."},{"role":"assistant","content":"def factorial(n):\n if n == 0:\n return 1\n return n * factorial(n - 1)"}]}
|
| 88 |
+
|
| 89 |
+
{"messages":[{"role":"user","content":"I want a C++ example for returning a boolean function."},{"role":"assistant","content":"bool check(int n) {\n return n > 0;\n}"}]}
|
| 90 |
+
|
| 91 |
+
{"messages":[{"role":"user","content":"Show me how to access object properties in JavaScript."},{"role":"assistant","content":"obj.property"}]}
|
| 92 |
+
|
| 93 |
+
{"messages":[{"role":"user","content":"I need a Python example for checking file existence."},{"role":"assistant","content":"import os\nos.path.exists(\"file.txt\")"}]}
|
| 94 |
+
|
| 95 |
+
{"messages":[{"role":"user","content":"Show me how to round a number in Python."},{"role":"assistant","content":"round(x)"}]}
|
| 96 |
+
|
| 97 |
+
{"messages":[{"role":"user","content":"I want a Rust example for matching a number."},{"role":"assistant","content":"match n {\n 1 => println!(\"one\"),\n _ => println!(\"other\"),\n}"}]}
|
| 98 |
+
|
| 99 |
+
{"messages":[{"role":"user","content":"Show me how to convert a string to float in Python."},{"role":"assistant","content":"float(s)"}]}
|
| 100 |
+
|
| 101 |
+
{"messages":[{"role":"user","content":"I need a Java example for trimming whitespace."},{"role":"assistant","content":"s.trim();"}]}
|