[ { "prompt": "Write hello world on python. It should return \"Hello, World!\". Write it to main.py, use double quotes.", "expected": { "main.py": "print(\"Hello, World!\")" }, "start": {}, "web": {} }, { "prompt": "Fetch https://cdn.github.ru/test and write contents to test.txt", "expected": { "test.txt": "Moo!" }, "start": {}, "web": { "https://cdn.github.ru/test": "Moo!" } }, { "prompt": "Read greetings.html, change 'World' to 'Cow' and save back", "start": { "greetings.html": "
\\nFact:'.", "expected": { "daily.txt": "Quote: To be or not to be\nFact: Cows have four stomachs" }, "start": {}, "web": { "https://api.quotes.cow/random": "To be or not to be", "https://api.facts.cow/random": "Cows have four stomachs" } }, { "prompt": "Read transactions.csv with columns: date,amount,type (income/expense). Compute total income, total expense, and net balance. Write to summary.txt as 'Income: X\\nExpense: Y\\nNet: Z'.", "expected": { "summary.txt": "Income: 300\nExpense: 80\nNet: 220" }, "start": { "transactions.csv": "2026-01-01,100,income\n2026-01-02,50,expense\n2026-01-03,200,income\n2026-01-04,30,expense" }, "web": {} }, { "prompt": "Read files.txt, which contains a list of filenames. For each file, if it exists and contains the word 'ERROR', then rename it by prepending 'error_' (e.g., log.txt -> error_log.txt).", "expected": { "files.txt": "log1.txt\nlog2.txt\nlog3.txt", "log1.txt": "INFO: success", "error_log2.txt": "ERROR: disk full", "log3.txt": "WARN: low memory" }, "start": { "files.txt": "log1.txt\nlog2.txt\nlog3.txt", "log1.txt": "INFO: success", "log2.txt": "ERROR: disk full", "log3.txt": "WARN: low memory" }, "web": {} }, { "prompt": "Fetch a random number from https://api.random.cow/number (returns plain integer). Read nums.txt (one number per line). Multiply each number by the random number and write results to multiplied.txt, one per line.", "expected": { "multiplied.txt": "10\n15\n20" }, "start": { "nums.txt": "2\n3\n4" }, "web": { "https://api.random.cow/number": "5" } }, { "prompt": "Read config.json, which contains a key 'urls' (array of URLs). Fetch each URL and concatenate their contents with a blank line between, and write to combined.txt.", "expected": { "combined.txt": "Content A\n\nContent B" }, "start": { "config.json": "{\"urls\":[\"https://example.com/a\",\"https://example.com/b\"]}" }, "web": { "https://example.com/a": "Content A", "https://example.com/b": "Content B" } }, { "prompt": "Read grades.csv with columns: name,subject,grade (numeric). For each student, compute GPA (average grade) and output sorted descending by GPA to gpa.csv with format: name,GPA (two decimals).", "expected": { "gpa.csv": "Charlie,95.00\nAlice,85.00\nBob,76.67" }, "start": { "grades.csv": "Alice,Math,90\nAlice,Science,80\nBob,Math,70\nBob,Science,75\nBob,English,85\nCharlie,Math,95" }, "web": {} }, { "prompt": "Read log.txt with lines: 'timestamp level message' (e.g., '2026-06-01 10:00 INFO Started'). Keep only lines with level ERROR or WARN. Then sort them by timestamp ascending. Write to filtered.log with the original line format.", "expected": { "filtered.log": "2026-06-01 12:05 WARN Memory low\n2026-06-01 12:10 ERROR Disk full" }, "start": { "log.txt": "2026-06-01 12:00 INFO Startup\n2026-06-01 12:05 WARN Memory low\n2026-06-01 12:10 ERROR Disk full\n2026-06-01 12:15 INFO Shutdown" }, "web": {} }, { "prompt": "Fetch version1.txt from https://files.cow.ru/v1 and version2.txt from https://files.cow.ru/v2. Write to diff.txt the lines that are different, with prefix '-' for lines only in v1 and '+' for lines only in v2.", "expected": { "diff.txt": "- line3\n+ line4" }, "start": {}, "web": { "https://files.cow.ru/v1": "line1\nline2\nline3", "https://files.cow.ru/v2": "line1\nline2\nline4" } }, { "prompt": "Read settings.txt with lines key=value. If there is a line with key 'status', change its value to 'active'. If not, add a line 'status=active' at the end. Write to updated_settings.txt.", "expected": { "updated_settings.txt": "mode=prod\ndebug=true\nstatus=active" }, "start": { "settings.txt": "mode=prod\ndebug=true" }, "web": {} }, { "prompt": "Read paths.txt (list of filenames). For each filename, fetch content from https://files.cow.ru/contents/ and save it to that filename locally.", "expected": { "paths.txt": "a.txt\nb.txt\nc.txt", "a.txt": "content of a", "b.txt": "content of b", "c.txt": "content of c" }, "start": { "paths.txt": "a.txt\nb.txt\nc.txt" }, "web": { "https://files.cow.ru/contents/a.txt": "content of a", "https://files.cow.ru/contents/b.txt": "content of b", "https://files.cow.ru/contents/c.txt": "content of c" } }, { "prompt": "Read file1.txt and file2.txt. Write all lines that appear in both files to common.txt (preserve order from file1).", "expected": { "common.txt": "banana\ndate" }, "start": { "file1.txt": "apple\nbanana\ncherry\ndate", "file2.txt": "banana\ndate\negg" }, "web": {} }, { "prompt": "Read data.csv with header row (name,age,city). Generate a markdown table with header row and separator line, and write to table.md.", "expected": { "table.md": "| name | age | city |\n| --- | --- | --- |\n| Alice | 30 | Moscow |\n| Bob | 25 | Chelyabinsk |" }, "start": { "data.csv": "name,age,city\nAlice,30,Moscow\nBob,25,Chelyabinsk" }, "web": {} }, { "prompt": "Fetch https://api.cow.ru/manifest.json which returns a JSON array of filenames. Delete any files in the current directory (except manifest.json itself) that are not listed in the manifest. Keep the listed files unchanged. Do not create any new files.", "start": { "file1.txt": "keep me", "file2.txt": "delete me", "file3.txt": "keep me too" }, "expected": { "file1.txt": "keep me", "file3.txt": "keep me too" }, "web": { "https://api.cow.ru/manifest.json": "[\"file1.txt\",\"file3.txt\"]" } }, { "prompt": "Read data.csv with column 'value'. Compute the z‑score for each value (subtract the mean, divide by the standard deviation). Write the original rows plus a new column 'zscore' to zscores.csv. Keep data.csv unchanged.", "start": { "data.csv": "value\n10\n20\n30\n40" }, "expected": { "data.csv": "value\n10\n20\n30\n40", "zscores.csv": "value,zscore\n10,-1.34\n20,-0.45\n30,0.45\n40,1.34" }, "web": {} }, { "prompt": "Read log.txt. Move every line that contains the word 'ERROR' to error.log (append if error.log already exists). Remove those lines from log.txt completely. Keep the remaining lines in log.txt.", "start": { "log.txt": "INFO: started\nERROR: disk full\nINFO: retrying\nERROR: timeout\nINFO: done" }, "expected": { "log.txt": "INFO: started\nINFO: retrying\nINFO: done", "error.log": "ERROR: disk full\nERROR: timeout" }, "web": {} }, { "prompt": "Fetch https://files.cow.ru/v1.txt and https://files.cow.ru/v2.txt. Write a unified diff to diff.txt: lines that are in v1 but not v2 should be prefixed with '-', lines in v2 but not v1 with '+'. Lines common to both are omitted. Do not create any other files.", "start": {}, "expected": { "diff.txt": "- line3\n+ line4" }, "web": { "https://files.cow.ru/v1.txt": "line1\nline2\nline3", "https://files.cow.ru/v2.txt": "line1\nline2\nline4" } }, { "prompt": "Read sales.csv with columns: date,product,units,price. Compute total revenue (units * price) for each product. Write a CSV file revenue.csv with columns product,revenue, sorted by revenue descending. Keep sales.csv unchanged.", "start": { "sales.csv": "date,product,units,price\n2026-01-01,A,10,5\n2026-01-02,B,5,20\n2026-01-03,A,3,5\n2026-01-04,C,8,10" }, "expected": { "sales.csv": "date,product,units,price\n2026-01-01,A,10,5\n2026-01-02,B,5,20\n2026-01-03,A,3,5\n2026-01-04,C,8,10", "revenue.csv": "product,revenue\nB,100\nC,80\nA,65" }, "web": {} }, { "prompt": "Read dirs.json which contains a list of file paths (relative to the current directory). For each path, create the file with the content 'auto-generated'. If a file already exists, leave its content unchanged. Then delete any file in the current directory that is NOT listed in dirs.json (including hidden files, but keep dirs.json itself).", "start": { "dirs.json": "[\"keep1.txt\",\"keep2.txt\"]", "keep1.txt": "old content", "delete_me.txt": "should vanish", "keep2.txt": "also old" }, "expected": { "dirs.json": "[\"keep1.txt\",\"keep2.txt\"]", "keep1.txt": "old content", "keep2.txt": "also old" }, "web": {} }, { "prompt": "Read doc.md. Extract all fenced code blocks (delimited by ```). Save each block to a separate file named code_1.txt, code_2.txt, … in the order they appear. Write only the code content (without the fences). Keep doc.md unchanged.", "start": { "doc.md": "# Example\n```python\nprint('hello')\n```\nSome text\n```bash\necho moo\n```" }, "expected": { "doc.md": "# Example\n```python\nprint('hello')\n```\nSome text\n```bash\necho moo\n```", "code_1.txt": "print('hello')", "code_2.txt": "echo moo" }, "web": {} }, { "prompt": "Read keep.txt which contains one filename per line. Delete all other files in the current directory, but keep keep.txt itself and the files listed inside it. Do not modify the contents of the kept files.", "start": { "keep.txt": "a.txt\nb.txt", "a.txt": "important", "b.txt": "also important", "c.txt": "delete me", "d.log": "delete me too" }, "expected": { "keep.txt": "a.txt\nb.txt", "a.txt": "important", "b.txt": "also important" }, "web": {} }, { "prompt": "Fetch https://config.cow.ru/settings.json (a JSON object). Read template.txt which contains placeholders in the format {{key}}. Replace every occurrence of {{key}} with the corresponding value from the JSON object. Write the result to final.txt. Do not modify template.txt.", "start": { "template.txt": "Hello {{name}}, your role is {{role}}." }, "expected": { "template.txt": "Hello {{name}}, your role is {{role}}.", "final.txt": "Hello Alice, your role is admin." }, "web": { "https://config.cow.ru/settings.json": "{\"name\":\"Alice\",\"role\":\"admin\"}" } }, { "prompt": "Read log.txt where each line is 'HH:MM level message'. Compute the average time difference (in minutes) between consecutive lines that have level 'ERROR'. If there are fewer than 2 ERROR lines, write 'N/A'. Otherwise write the average as a number with two decimal places to avg_error_interval.txt. Keep log.txt unchanged.", "start": { "log.txt": "08:00 INFO start\n08:15 ERROR disk\n08:30 INFO retry\n09:00 ERROR timeout\n09:10 INFO done" }, "expected": { "log.txt": "08:00 INFO start\n08:15 ERROR disk\n08:30 INFO retry\n09:00 ERROR timeout\n09:10 INFO done", "avg_error_interval.txt": "45.00" }, "web": {} }, { "prompt": "Read a.json and b.json. Perform a deep merge: if both objects have the same key, the value from b.json overrides the value from a.json. Nested objects are merged recursively. Write the merged result to merged.json. Keep a.json and b.json unchanged.", "start": { "a.json": "{\"version\":1,\"settings\":{\"theme\":\"dark\",\"lang\":\"en\"}}", "b.json": "{\"version\":2,\"settings\":{\"theme\":\"light\"}}" }, "expected": { "a.json": "{\"version\":1,\"settings\":{\"theme\":\"dark\",\"lang\":\"en\"}}", "b.json": "{\"version\":2,\"settings\":{\"theme\":\"light\"}}", "merged.json": "{\"version\":2,\"settings\":{\"theme\":\"light\",\"lang\":\"en\"}}" }, "web": {} }, { "prompt": "Read rename.txt which has lines in the format 'old_name new_name'. For each pair, rename the file old_name to new_name. If new_name already exists, skip that renaming and leave both files unchanged. If old_name does not exist, skip it. Keep rename.txt unchanged.", "start": { "rename.txt": "a.txt b.txt\nc.txt d.txt", "a.txt": "content A", "c.txt": "content C" }, "expected": { "rename.txt": "a.txt b.txt\nc.txt d.txt", "b.txt": "content A", "d.txt": "content C" }, "web": {} }, { "prompt": "Read files.txt which contains a list of filenames (one per line). For each file, compute its SHA‑256 hash. Group files that have identical hashes. Write to duplicates.txt: each group of duplicate files (size ≥ 2) on a line separated by commas, with a blank line between groups. Keep all files unchanged.", "start": { "files.txt": "f1.txt\nf2.txt\nf3.txt\nf4.txt", "f1.txt": "hello", "f2.txt": "world", "f3.txt": "hello", "f4.txt": "moo" }, "expected": { "files.txt": "f1.txt\nf2.txt\nf3.txt\nf4.txt", "f1.txt": "hello", "f2.txt": "world", "f3.txt": "hello", "f4.txt": "moo", "duplicates.txt": "f1.txt, f3.txt" }, "web": {} }, { "prompt": "Read grades.csv with columns 'name' and 'score'. Compute a letter grade: A for score ≥ 90, B for ≥ 80, C for ≥ 70, D for ≥ 60, F for < 60. Write to report.csv with columns name,score,grade, sorted by score descending. Keep grades.csv unchanged.", "start": { "grades.csv": "name,score\nAlice,95\nBob,82\nCharlie,67\nDiana,58" }, "expected": { "grades.csv": "name,score\nAlice,95\nBob,82\nCharlie,67\nDiana,58", "report.csv": "name,score,grade\nAlice,95,A\nBob,82,B\nCharlie,67,D\nDiana,58,F" }, "web": {} }, { "prompt": "Fetch https://commands.cow.ru/actions.txt. Each line is either 'create ' or 'delete '. Execute the commands in order: for 'create', create (or overwrite) the file with the given content; for 'delete', remove the file if it exists. Do not create or modify any other files. Do not modify actions.txt locally.", "start": { "existing.txt": "I am here", "keep_me.txt": "do not touch" }, "expected": { "keep_me.txt": "do not touch", "new_file.txt": "this is new", "overwritten.txt": "new content" }, "web": { "https://commands.cow.ru/actions.txt": "create new_file.txt this is new\ndelete existing.txt\ncreate overwritten.txt new content" } }, { "prompt": "Read inventory.json (array of {item, qty}). For any item with qty < 5, set qty to 10. Write the updated array to restocked.json. Keep inventory.json unchanged. Then delete any file whose name starts with 'temp_' (e.g., temp_1.log, temp_data.txt) if present.", "start": { "inventory.json": "[{\"item\":\"milk\",\"qty\":3},{\"item\":\"bread\",\"qty\":10},{\"item\":\"eggs\",\"qty\":1}]", "temp_1.log": "ignore me", "temp_data.txt": "also ignore" }, "expected": { "inventory.json": "[{\"item\":\"milk\",\"qty\":3},{\"item\":\"bread\",\"qty\":10},{\"item\":\"eggs\",\"qty\":1}]", "restocked.json": "[{\"item\":\"milk\",\"qty\":10},{\"item\":\"bread\",\"qty\":10},{\"item\":\"eggs\",\"qty\":10}]" }, "web": {} }, { "prompt": "Read employees.csv (name,department,salary). Compute the average salary per department. Write a CSV report dept_avg.csv with columns department,avg_salary, sorted by avg_salary descending. Then delete any file named 'old_*.bak' (if present). Keep employees.csv unchanged.", "start": { "employees.csv": "name,department,salary\nAlice,IT,100\nBob,HR,80\nCharlie,IT,90\nDiana,HR,70", "old_backup.bak": "delete me" }, "expected": { "employees.csv": "name,department,salary\nAlice,IT,100\nBob,HR,80\nCharlie,IT,90\nDiana,HR,70", "dept_avg.csv": "department,avg_salary\nIT,95.0\nHR,75.0" }, "web": {} }, { "prompt": "Read data.txt which contains lines of numbers (one per line). Compute the cumulative sum and write each cumulative sum to cumulative.txt (one per line). Remove the original data.txt after writing cumulative.txt.", "start": { "data.txt": "10\n20\n30" }, "expected": { "cumulative.txt": "10\n30\n60" }, "web": {} }, { "prompt": "Fetch https://api.cow.ru/users.json (array of {id, name}) and https://api.cow.ru/status.json (object mapping id->status). Merge the data into a single CSV file users_status.csv with columns id,name,status. Then delete any file with extension '.tmp' in the current directory. Keep fetched data as is (no local copies).", "start": { "temp.tmp": "should vanish" }, "expected": { "users_status.csv": "id,name,status\n1,Alice,active\n2,Bob,inactive\n3,Charlie,active" }, "web": { "https://api.cow.ru/users.json": "[{\"id\":1,\"name\":\"Alice\"},{\"id\":2,\"name\":\"Bob\"},{\"id\":3,\"name\":\"Charlie\"}]", "https://api.cow.ru/status.json": "{\"1\":\"active\",\"2\":\"inactive\",\"3\":\"active\"}" } }, { "prompt": "Read fileA.txt and fileB.txt. Write all lines that appear in fileA but not in fileB to onlyA.txt. Then delete fileB.txt entirely.", "start": { "fileA.txt": "apple\nbanana\ncherry", "fileB.txt": "banana\ndate" }, "expected": { "fileA.txt": "apple\nbanana\ncherry", "onlyA.txt": "apple\ncherry" }, "web": {} }, { "prompt": "Read log.txt with timestamps (format: YYYY-MM-DD HH:MM:SS level message). Write only lines from the last 24 hours (based on current time, assume the current time is 2026-06-18 12:00:00) to recent.log. Then compress (just rename) the original log.txt to log_old.txt, keeping both files.", "start": { "log.txt": "2026-06-17 10:00 INFO startup\n2026-06-18 11:00 ERROR crash\n2026-06-18 13:00 WARN retry" }, "expected": { "recent.log": "2026-06-18 11:00 ERROR crash\n2026-06-18 13:00 WARN retry", "log_old.txt": "2026-06-17 10:00 INFO startup\n2026-06-18 11:00 ERROR crash\n2026-06-18 13:00 WARN retry" }, "web": {} }, { "prompt": "Read contacts.csv (name,phone,email). Generate a vCard (.vcf) file for each person named .vcf with format: 'BEGIN:VCARD\\nFN:name\\nTEL:phone\\nEMAIL:email\\nEND:VCARD'. Then delete the original contacts.csv.", "start": { "contacts.csv": "name,phone,email\nAlice,+123,alice@cow.ru\nBob,+456,bob@cow.ru" }, "expected": { "Alice.vcf": "BEGIN:VCARD\nFN:Alice\nTEL:+123\nEMAIL:alice@cow.ru\nEND:VCARD", "Bob.vcf": "BEGIN:VCARD\nFN:Bob\nTEL:+456\nEMAIL:bob@cow.ru\nEND:VCARD" }, "web": {} }, { "prompt": "Read config.json which contains a 'version' field. Increment the version by 1. Also, if there is a field 'last_update', update it to the current date (2026-06-18). Write the updated config to config_new.json. Keep config.json unchanged, but delete any file named 'backup_*.json' if present.", "start": { "config.json": "{\"version\":3,\"app\":\"test\"}", "backup_1.json": "old" }, "expected": { "config.json": "{\"version\":3,\"app\":\"test\"}", "config_new.json": "{\"version\":4,\"app\":\"test\",\"last_update\":\"2026-06-18\"}" }, "web": {} }, { "prompt": "Read scores.txt (one score per line). Compute the standard deviation (population) of the scores. Write the result to stddev.txt as a number with two decimals. Remove scores.txt after computing.", "start": { "scores.txt": "10\n20\n30\n40" }, "expected": { "stddev.txt": "11.18" }, "web": {} }, { "prompt": "Fetch https://api.weather.cow/forecast.json which returns {hourly: [temp, ...]}. Write only the temperatures to temps.txt, one per line. Then delete any file with name 'cache_*.dat' if present.", "start": { "cache_1.dat": "old cache" }, "expected": { "temps.txt": "15\n18\n20\n17" }, "web": { "https://api.weather.cow/forecast.json": "{\"hourly\":[15,18,20,17]}" } }, { "prompt": "Read poem.txt. Reverse the order of lines and also reverse the characters in each line, but keep the line order reversed (i.e., last line first, and each line reversed). Write to reversed_poem.txt. Keep poem.txt unchanged. Then delete any file ending with '.bak'.", "start": { "poem.txt": "Roses are red\nViolets are blue\nCows say moo", "old.bak": "ignore" }, "expected": { "poem.txt": "Roses are red\nViolets are blue\nCows say moo", "reversed_poem.txt": "oom yas swoC\neulb era steloiv\nder era sesoR" }, "web": {} }, { "prompt": "Read data.csv (name,age). Create a new file adult.txt containing only names of people aged 18 or older, one per line. Then delete all files with name starting with 'child_' (e.g., child_1.txt) if present.", "start": { "data.csv": "name,age\nAlice,25\nBob,17\nCharlie,30", "child_1.txt": "irrelevant" }, "expected": { "data.csv": "name,age\nAlice,25\nBob,17\nCharlie,30", "adult.txt": "Alice\nCharlie" }, "web": {} }, { "prompt": "Fetch https://files.cow.ru/list.txt which contains a list of filenames (one per line). For each filename, fetch the content from https://files.cow.ru/contents/ and save it to the local file with that name. Then delete list.txt after all fetches.", "start": {}, "expected": { "a.txt": "content a", "b.txt": "content b", "c.txt": "content c" }, "web": { "https://files.cow.ru/list.txt": "a.txt\nb.txt\nc.txt", "https://files.cow.ru/contents/a.txt": "content a", "https://files.cow.ru/contents/b.txt": "content b", "https://files.cow.ru/contents/c.txt": "content c" } }, { "prompt": "Read transactions.csv (date,amount). Compute the 7-day moving average of amount (assuming dates are consecutive). Write to moving_avg.csv with columns date,avg. Keep transactions.csv unchanged. Then delete any file with '.old' extension.", "start": { "transactions.csv": "date,amount\n2026-06-01,10\n2026-06-02,20\n2026-06-03,30\n2026-06-04,40\n2026-06-05,50\n2026-06-06,60\n2026-06-07,70", "backup.old": "remove" }, "expected": { "transactions.csv": "date,amount\n2026-06-01,10\n2026-06-02,20\n2026-06-03,30\n2026-06-04,40\n2026-06-05,50\n2026-06-06,60\n2026-06-07,70", "moving_avg.csv": "date,avg\n2026-06-04,25.0\n2026-06-05,30.0\n2026-06-06,35.0\n2026-06-07,40.0" }, "web": {} }, { "prompt": "Read file1.txt and file2.txt. If their contents are identical, delete file2.txt and rename file1.txt to master.txt. If different, do nothing to files, but write 'different' to status.txt. Keep the original files as per condition.", "start": { "file1.txt": "same content", "file2.txt": "same content" }, "expected": { "master.txt": "same content" }, "web": {} }, { "prompt": "Read file1.txt and file2.txt. If their contents are identical, delete file2.txt and rename file1.txt to master.txt. If different, do nothing to files, but write 'different' to status.txt. Keep the original files as per condition.", "start": { "file1.txt": "content A", "file2.txt": "content B" }, "expected": { "file1.txt": "content A", "file2.txt": "content B", "status.txt": "different" }, "web": {} }, { "prompt": "Read data.json (array of objects with 'id' and 'value'). Find the object with the maximum value and write its id to max_id.txt. Then remove that object from the array and write the remaining to data_trimmed.json. Keep data.json unchanged.", "start": { "data.json": "[{\"id\":1,\"value\":10},{\"id\":2,\"value\":25},{\"id\":3,\"value\":15}]" }, "expected": { "data.json": "[{\"id\":1,\"value\":10},{\"id\":2,\"value\":25},{\"id\":3,\"value\":15}]", "max_id.txt": "2", "data_trimmed.json": "[{\"id\":1,\"value\":10},{\"id\":3,\"value\":15}]" }, "web": {} }, { "prompt": "Read text.txt. Replace all digits (0-9) with '#' and write to masked.txt. Then delete any file named 'original_*' if present.", "start": { "text.txt": "My phone: 123-456-7890", "original_backup.txt": "ignore" }, "expected": { "text.txt": "My phone: 123-456-7890", "masked.txt": "My phone: ###-###-####" }, "web": {} }, { "prompt": "Fetch https://api.cow.ru/movie_ratings.json (array of {title, rating}). Write a report report.txt with each title and rating, sorted by rating descending, formatted as 'Title: rating'. Then delete the downloaded data (no local copy).", "start": {}, "expected": { "report.txt": "The Matrix: 9.0\nInception: 8.8\nInterstellar: 8.6" }, "web": { "https://api.cow.ru/movie_ratings.json": "[{\"title\":\"The Matrix\",\"rating\":9.0},{\"title\":\"Inception\",\"rating\":8.8},{\"title\":\"Interstellar\",\"rating\":8.6}]" } }, { "prompt": "Read config.ini which contains key=value pairs. Look for a key 'log_level'. If it exists, change its value to 'DEBUG'. If not, add a line 'log_level=DEBUG'. Write the updated config to config.ini (overwrite). Keep a backup of the original as config.ini.bak.", "start": { "config.ini": "mode=prod\nport=8080" }, "expected": { "config.ini": "mode=prod\nport=8080\nlog_level=DEBUG", "config.ini.bak": "mode=prod\nport=8080" }, "web": {} }, { "prompt": "Read data.csv (name,score1,score2). For each row, compute the average and a grade: A if average>=90, B>=80, C>=70, D>=60, else F. Write to grades.csv with columns name,avg,grade. Then delete data.csv.", "start": { "data.csv": "name,score1,score2\nAlice,95,85\nBob,70,60\nCharlie,50,40" }, "expected": { "grades.csv": "name,avg,grade\nAlice,90.0,A\nBob,65.0,D\nCharlie,45.0,F" }, "web": {} }, { "prompt": "Read urls.txt (one URL per line). For each URL, fetch its content and count the number of words (space-separated). Write a CSV report url_wordcount.csv with columns url,wordcount. Keep urls.txt unchanged. Then delete any file with extension '.cache'.", "start": { "urls.txt": "https://example.com/a\nhttps://example.com/b", "temp.cache": "remove" }, "expected": { "urls.txt": "https://example.com/a\nhttps://example.com/b", "url_wordcount.csv": "url,wordcount\nhttps://example.com/a,5\nhttps://example.com/b,3" }, "web": { "https://example.com/a": "Hello world from cow", "https://example.com/b": "Moo moo" } }, { "prompt": "Read secret.txt. Apply ROT13 (shift letters by 13) to the entire content and write to encrypted.txt. Then delete secret.txt.", "start": { "secret.txt": "Hello Cow" }, "expected": { "encrypted.txt": "Uryyb Pbj" }, "web": {} }, { "prompt": "Read orders.csv (order_id, customer, amount). Filter orders with amount > 100. Write the filtered orders to large_orders.csv. Then delete any file with name starting with 'small_' if present.", "start": { "orders.csv": "order_id,customer,amount\n1,Alice,50\n2,Bob,150\n3,Charlie,120\n4,Diana,80", "small_1.csv": "ignore" }, "expected": { "orders.csv": "order_id,customer,amount\n1,Alice,50\n2,Bob,150\n3,Charlie,120\n4,Diana,80", "large_orders.csv": "order_id,customer,amount\n2,Bob,150\n3,Charlie,120" }, "web": {} }, { "prompt": "Read file.txt. Count the number of lines, words, and characters (excluding newlines). Write a summary in format: 'lines: X, words: Y, chars: Z' to stats.txt. Then rename file.txt to file_backup.txt.", "start": { "file.txt": "hello world\nmoo cow" }, "expected": { "stats.txt": "lines: 2, words: 4, chars: 18", "file_backup.txt": "hello world\nmoo cow" }, "web": {} }, { "prompt": "Fetch https://api.cow.ru/team.json which returns an array of member names. Create a directory (though only files are simulated) – but we can simulate by creating a file per member with content 'Member: '. Write each to .txt. Also create a file team_list.txt containing all names, one per line. Then delete the original JSON (no local copy).", "start": {}, "expected": { "Alice.txt": "Member: Alice", "Bob.txt": "Member: Bob", "Charlie.txt": "Member: Charlie", "team_list.txt": "Alice\nBob\nCharlie" }, "web": { "https://api.cow.ru/team.json": "[\"Alice\",\"Bob\",\"Charlie\"]" } }, { "prompt": "Read numbers.txt (one integer per line). Compute the product of all numbers (use arbitrary precision). Write the product to product.txt. Then remove numbers.txt.", "start": { "numbers.txt": "2\n3\n4" }, "expected": { "product.txt": "24" }, "web": {} }, { "prompt": "Read data.csv (name,score). Sort the rows by score ascending and write to sorted_asc.csv. Then delete data.csv.", "start": { "data.csv": "name,score\nAlice,75\nBob,30\nCharlie,90" }, "expected": { "sorted_asc.csv": "name,score\nBob,30\nAlice,75\nCharlie,90" }, "web": {} }, { "prompt": "Fetch https://api.cow.ru/quote.txt (plain text) and https://api.cow.ru/author.txt (plain text). Combine them into a single file quote_author.txt with format: 'Quote: \\nAuthor:'. Then delete any file named 'temp_*' if present.", "start": { "temp_quote": "remove me" }, "expected": { "quote_author.txt": "Quote: To be or not to be\nAuthor: Shakespeare" }, "web": { "https://api.cow.ru/quote.txt": "To be or not to be", "https://api.cow.ru/author.txt": "Shakespeare" } }, { "prompt": "Read log.txt (each line is a message). Find the longest line by character count. Write that line to longest.txt. Also write its length to length.txt (just the number). Keep log.txt unchanged. Then delete any file with extension '.log' except log.txt.", "start": { "log.txt": "short\nthis is a longer line\nmedium", "old.log": "delete me" }, "expected": { "log.txt": "short\nthis is a longer line\nmedium", "longest.txt": "this is a longer line", "length.txt": "21" }, "web": {} } ]