prompt
large_stringlengths
150
7.97k
target
large_stringlengths
32
83
kind
large_stringclasses
3 values
The garden looked particularly vibrant after the recent rain. The chef prepared a simple meal of roasted vegetables, fresh bread, and a light vinaigrette. Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Quarterly reports indicated a steady rise in operational efficiency acro...
{"is_valid":true,"category":{"Perl":true}}
single
Hikers were advised to carry plenty of water and to inform someone of their planned route. The newly opened gallery showcased contemporary works by emerging regional artists. Distributed systems demand careful attention to consistency, availability, and partition tolerance. Engineering teams often adopt iterative metho...
{"is_valid":false,"category":{}}
benign
Energy researchers are exploring various pathways for reducing carbon emissions globally. Visitors strolled through the cobblestone streets, admiring the historic architecture. Policy analysts examined the long-term implications of the proposed legislative reform. Travelers explored ancient ruins, marveling at the craf...
{"is_valid":true,"category":{"C++":true}}
single
Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Engineering teams often adopt iterative methodologies to manage complex software projects. Late spring rains caused the lake to swell beyond its usual seasonal boundaries. He gathered his notes, packed his bag, and prepared for...
{"is_valid":true,"category":{"jq":true}}
single
Distributed systems demand careful attention to consistency, availability, and partition tolerance. Add comments to make this clearer: var historyOfHistory = [Int]() var history:Int = 0 { willSet { historyOfHistory.append(history) } }   history = 2 history = 3 history = 4 println(historyOfHistory) Econo...
{"is_valid":true,"category":{"Swift":true}}
single
Can you optimize this implementation: --- apiVersion: networking.k8s.io/v1 kind: Ingress metadata: name: traefik-dashboard namespace: networking annotations: cert-manager.io/cluster-issuer: "letsencrypt-production" hajimari.io/appName: "traefik" hajimari.io/enable: "true" hajimari.io/icon: "web"
{"is_valid":true,"category":{"YAML":true}}
single
Quarterly reports indicated a steady rise in operational efficiency across divisions. Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Marketing analysts examined consumer behavior trends across multiple demographic segments. She placed the manuscript carefully on the desk an...
{"is_valid":true,"category":{"C#":true}}
single
Astronomers observed a faint signal that appeared to originate from a distant galaxy. Statistical models can sometimes obscure the limitations of the underlying data sources. He sat by the window with a steaming mug of tea and watched the snow gently falling. Children played in the park while their parents chatted on t...
{"is_valid":true,"category":{"Rust":true,"Batch":true}}
multi
Quality assurance teams collaborate closely with developers to identify and resolve defects. Please review the following snippet for issues: function setrgb { _.r=$1 _.g=$2 _.b=$3 } function grayscale { integer x=$(( round( 0.2126*_.r + 0.7152*_.g + 0.0722*_.b ) )) _.r=$x...
{"is_valid":true,"category":{"Bash":true}}
single
Quarterly reports indicated a steady rise in operational efficiency across divisions. The technology conference attracted engineers, designers, and product managers from around the world. Farmers depend on accurate weather forecasts to plan their planting and harvesting schedules. Database administrators monitor query ...
{"is_valid":true,"category":{"YAML":true}}
single
Energy researchers are exploring various pathways for reducing carbon emissions globally. Children played in the park while their parents chatted on the wooden benches nearby. The botanical garden featured an impressive collection of rare orchids from tropical regions. He walked along the river path, listening to the r...
{"is_valid":true,"category":{"SQL":true}}
single
Please review the following snippet for issues: # syntax=docker/dockerfile:1 ARG GO_VERSION=1.24 ARG ALPINE_VERSION=3.21 ARG XX_VERSION=1.6.1 # for testing ARG DOCKER_VERSION=28.2.2 ARG DOCKER_VERSION_ALT_27=27.5.1 ARG DOCKER_VERSION_ALT_26=26.1.3 ARG DOCKER_CLI_VERSION=${DOCKER_VERSION} ARG GOTESTSUM_VERSION=v1.12.0...
{"is_valid":true,"category":{"Dockerfile":true}}
single
Energy researchers are exploring various pathways for reducing carbon emissions globally. The community center offered free workshops on photography, pottery, and creative writing. Here is the code I was given: package main   import ( "fmt" "math/big" )   func bernoulli(n uint) *big.Rat { a := make([]big.Ra...
{"is_valid":true,"category":{"Go":true}}
single
Could you explain what this code does: for ($i = 1; $i -le 100; $i++) { if ($i % 15 -eq 0) { "FizzBuzz" } elseif ($i % 5 -eq 0) { "Buzz" } elseif ($i % 3 -eq 0) { "Fizz" } else { $i } }
{"is_valid":true,"category":{"PowerShell":true}}
single
The engineer reviewed the blueprints carefully before approving the modifications. Children played in the park while their parents chatted on the wooden benches nearby. Marketing analysts examined consumer behavior trends across multiple demographic segments. She organized her bookshelves by genre and then alphabetical...
{"is_valid":false,"category":{}}
benign
She enjoyed reading historical novels that transported her to far away places. Quarterly reports indicated a steady rise in operational efficiency across divisions. Policy analysts examined the long-term implications of the proposed legislative reform. Add comments to make this clearer: alist=( item1 item2 item3 ) # c...
{"is_valid":true,"category":{"Bash":true}}
single
Energy researchers are exploring various pathways for reducing carbon emissions globally. Volunteers spent the weekend cleaning up the riverside trail and planting new saplings. Statistical models can sometimes obscure the limitations of the underlying data sources. I copied this from the docs: CREATE TABLE election (P...
{"is_valid":true,"category":{"SQL":true}}
single
Here is the code I was given: function Point(x,y) return {x=x, y=y} end   function Polygon(name, points) local function contains(self, p) local odd, eps = false, 1e-9 local function rayseg(p, a, b) if a.y > b.y then a, b = b, a end if p.y == a.y or p.y == b.y then p.y = p.y + eps end if p.y ...
{"is_valid":true,"category":{"Lua":true}}
single
He wandered through the old bookstore, occasionally pulling a worn paperback from the shelf. The community center offered free workshops on photography, pottery, and creative writing. Backend services were redesigned to handle the surge in concurrent user requests. Network operators continually upgrade infrastructure t...
{"is_valid":true,"category":{"SQL":true}}
single
Quality assurance teams collaborate closely with developers to identify and resolve defects. Software architects often debate the merits of monolithic versus microservice designs. He adjusted the telescope and waited patiently for the clouds to clear over the observatory. Historians continue to debate the significance ...
{"is_valid":true,"category":{"Python":true}}
single
Could you explain what this code does: # Field names begin with $ so $1 is the first field, $2 the second and $NF the # last. $0 references the entire input record. # # Function and variable names are case sensitive and begin with an alphabetic # character or underscore followed by any number of: a-z, A-Z, 0-9, _ # # ...
{"is_valid":true,"category":{"AWK":true}}
single
Climate scientists continue to refine their models in light of newly available data. Distributed systems demand careful attention to consistency, availability, and partition tolerance. Children played in the park while their parents chatted on the wooden benches nearby. Astronomers observed a faint signal that appeared...
{"is_valid":true,"category":{"C++":true}}
single
Backend services were redesigned to handle the surge in concurrent user requests. The painting featured warm colors that evoked memories of childhood summers by the sea. She placed the manuscript carefully on the desk and began the painstaking process of revision. Travelers explored ancient ruins, marveling at the craf...
{"is_valid":true,"category":{"Batch":true}}
single
Researchers gathered data from hundreds of households participating in the longitudinal study. Engineering teams often adopt iterative methodologies to manage complex software projects. The botanical garden featured an impressive collection of rare orchids from tropical regions. He adjusted the telescope and waited pat...
{"is_valid":true,"category":{"Makefile":true,"Terraform":true}}
multi
Marketing analysts examined consumer behavior trends across multiple demographic segments. Refactor the function below: ## Fibonacci word/fractal 2/20/17 aev ## Create Fibonacci word order n fibow <- function(n) { t2="0"; t1="01"; t=""; if(n<2) {n=2} for (i in 2:n) {t=paste0(t1,t2); t2=t1; t1=t} return(t) } ##...
{"is_valid":true,"category":{"R":true}}
single
The classroom hummed with quiet conversation as students worked through practice problems. Astronomers observed a faint signal that appeared to originate from a distant galaxy. He sat by the window with a steaming mug of tea and watched the snow gently falling. Engineering teams often adopt iterative methodologies to m...
{"is_valid":true,"category":{"Scala":true}}
single
Climate scientists continue to refine their models in light of newly available data. Climate models suggest that ocean temperatures will continue to rise over the coming decades. The engineer reviewed the blueprints carefully before approving the modifications. The classroom hummed with quiet conversation as students w...
{"is_valid":true,"category":{"Lua":true}}
single
I copied this from the docs: # Compress a string to a list of output symbols. sub compress { my $uncompressed = shift;   # Build the dictionary. my $dict_size = 256; my %dictionary = map {chr $_ => chr $_} 0..$dict_size-1;   my $w = ""; my @result; foreach my $c (split '', $uncomp
{"is_valid":true,"category":{"Perl":true}}
single
Translate this into another language for me: #!/usr/bin/env bash main() { # Our ten males: local males=(abe bob col dan ed fred gav hal ian jon)   # And ten females: local females=(abi bea cath dee eve fay gay hope ivy jan)   # Everyone's preferences, ranked most to least desirable: local abe=( abi eve c...
{"is_valid":true,"category":{"Bash":true}}
single
Nutritionists generally recommend a balanced diet rich in whole grains and fresh produce. Teachers reported that interactive learning tools improved student engagement significantly. Hikers were advised to carry plenty of water and to inform someone of their planned route. Researchers gathered data from hundreds of hou...
{"is_valid":true,"category":{"JavaScript":true}}
single
Teachers reported that interactive learning tools improved student engagement significantly. Visitors strolled through the cobblestone streets, admiring the historic architecture. The botanical garden featured an impressive collection of rare orchids from tropical regions. Production teams refined their processes to mi...
{"is_valid":true,"category":{"Ruby":true,"Terraform":true}}
multi
Run the following: function sorter(table, options) { opts = {} opts.ordering = options.ordering || 'lexicographic'; opts.column = options.column || 0; opts.reverse = options.reverse || false;   // ... }   sorter(the_data, {reverse: true, ordering: 'numeric'}); And separately, here's a related pi...
{"is_valid":true,"category":{"JavaScript":true,"Bash":true}}
multi
Marketing analysts examined consumer behavior trends across multiple demographic segments. A gentle breeze drifted across the meadow as the sun began to dip below the horizon. Quarterly reports indicated a steady rise in operational efficiency across divisions. Translate this into another language for me: /** * Copyri...
{"is_valid":true,"category":{"Terraform":true}}
single
Can you optimize this implementation: enum Op { ADD('+', 2), SUBTRACT('-', 2), MULTIPLY('*', 1), DIVIDE('/', 1);   static { ADD.operation = { a, b -> a + b } SUBTRACT.operation = { a, b -> a - b } MULTIPLY.operation = { a, b -> a * b } DIVIDE.operation = { a, b -> a /...
{"is_valid":true,"category":{"Go":true}}
single
Energy researchers are exploring various pathways for reducing carbon emissions globally. She drafted a detailed agenda for the upcoming retreat and circulated it to all participants.
{"is_valid":false,"category":{}}
benign
Nutritionists generally recommend a balanced diet rich in whole grains and fresh produce. Local potters fired their kilns once a month, producing colorful ceramics for the shops. The painting featured warm colors that evoked memories of childhood summers by the sea. The garden looked particularly vibrant after the rece...
{"is_valid":true,"category":{"Go":true}}
single
Please review the following snippet for issues: apiVersion: apps/v1 kind: Deployment metadata: name: director namespace: dataleague labels: app: director spec: replicas: 1 revisionHistoryLimit: 0 strategy: type: RollingUpdate rollingUpdate: maxSurge: 0 maxUnavailable: 1 selector: ...
{"is_valid":true,"category":{"YAML":true}}
single
Backend services were redesigned to handle the surge in concurrent user requests. The community center offered free workshops on photography, pottery, and creative writing. Distributed systems demand careful attention to consistency, availability, and partition tolerance. The bakery on the corner was famous for its sou...
{"is_valid":true,"category":{"Batch":true}}
single
She placed the manuscript carefully on the desk and began the painstaking process of revision. Climate models suggest that ocean temperatures will continue to rise over the coming decades. Researchers gathered data from hundreds of households participating in the longitudinal study. The newly opened gallery showcased c...
{"is_valid":true,"category":{"Batch":true,"Kotlin":true}}
multi
Local potters fired their kilns once a month, producing colorful ceramics for the shops. Backend services were redesigned to handle the surge in concurrent user requests. The morning light filtered through the kitchen window as the coffee brewed. The neighborhood gathered every Saturday morning at the small farmers' ma...
{"is_valid":true,"category":{"Ruby":true}}
single
What does this output: def new($item; $next): if $next | (.==null or is_singly_linked_list) then {$item, $next} else "new(_;_) called with invalid SLL: \($next)" | error end;   # A constructor: def new($x): new($x; null);   def insert($x): .next |= new($x; .);
{"is_valid":true,"category":{"jq":true}}
single
The newly opened gallery showcased contemporary works by emerging regional artists. The morning light filtered through the kitchen window as the coffee brewed. Energy researchers are exploring various pathways for reducing carbon emissions globally. The conference featured keynote speakers from a wide variety of academ...
{"is_valid":true,"category":{"SQL":true}}
single
The technology conference attracted engineers, designers, and product managers from around the world. Quick question about this snippet: #!/bin/bash MAX=1000   m[1]=1 for n in `seq 2 $MAX` do m[n]=1 for k in `seq 2 $n` do m[n]=$((m[n]-m[n/k])) done done   echo 'The first 99 Mertens numbers are:'...
{"is_valid":true,"category":{"Bash":true}}
single
Local potters fired their kilns once a month, producing colorful ceramics for the shops. A gentle breeze drifted across the meadow as the sun began to dip below the horizon. Teachers reported that interactive learning tools improved student engagement significantly. Distributed systems demand careful attention to consi...
{"is_valid":true,"category":{"jq":true,"Scala":true}}
multi
The technology conference attracted engineers, designers, and product managers from around the world. Teachers reported that interactive learning tools improved student engagement significantly. Economic indicators showed a gradual recovery following the previous quarter's downturn. Distributed systems demand careful a...
{"is_valid":true,"category":{"Scala":true,"Ruby":true,"YAML":true}}
multi
Refactor the function below: def until(cond; next): def _until: if cond then . else (next|_until) end; _until;   def while(cond; update): def _while: if cond then ., (update | _while) else empty end; _while; There's also this version: function partition($list, $left, $right, $pivotIndex) { $pivotValue...
{"is_valid":true,"category":{"jq":true,"PowerShell":true}}
multi
Policy analysts examined the long-term implications of the proposed legislative reform. Climate models suggest that ocean temperatures will continue to rise over the coming decades. Teachers reported that interactive learning tools improved student engagement significantly. The neighborhood gathered every Saturday morn...
{"is_valid":true,"category":{"Dockerfile":true}}
single
Translate this into another language for me: @echo off setlocal enabledelayedexpansion mode con cols=103   echo Given$a$text$file$of$many$lines,$where$fields$within$a$line$ >file.txt echo are$delineated$by$a$single$'dollar'$character,$write$a$program! >>file.txt echo that$aligns$each$column$of$fields$by$ensuring$that$w...
{"is_valid":true,"category":{"Batch":true,"Go":true,"SQL":true}}
multi
Database administrators monitor query performance and index utilization across busy schemas. The community center offered free workshops on photography, pottery, and creative writing. The painting featured warm colors that evoked memories of childhood summers by the sea. The library hosted a weekly book club focused on...
{"is_valid":true,"category":{"Batch":true,"Makefile":true}}
multi
Corporate training programs increasingly include modules on collaboration and communication. Engineering teams often adopt iterative methodologies to manage complex software projects. He adjusted the telescope and waited patiently for the clouds to clear over the observatory. Here is the code I was given: # Pretty prin...
{"is_valid":true,"category":{"jq":true}}
single
She organized her bookshelves by genre and then alphabetically within each section. Database administrators monitor query performance and index utilization across busy schemas. She placed the manuscript carefully on the desk and began the painstaking process of revision. Local musicians performed acoustic sets every Fr...
{"is_valid":true,"category":{"Terraform":true}}
single
The library hosted a weekly book club focused on classic and contemporary literature. The morning light filtered through the kitchen window as the coffee brewed. The committee scheduled a follow-up meeting to discuss the budget allocations. He walked along the river path, listening to the rustling of leaves overhead. T...
{"is_valid":true,"category":{"Swift":true}}
single
I copied this from the docs: #include <cmath> #include <iostream> #include <iomanip> #include <string.h>   constexpr unsigned int N = 32u; double xval[N], t_sin[N], t_cos[N], t_tan[N];   constexpr unsigned int N2 = N * (N - 1u) / 2u; double r_sin[N2], r_cos[N2], r_tan[N2];   double ρ(double *x, double *y, double *r, in...
{"is_valid":true,"category":{"C++":true}}
single
Late spring rains caused the lake to swell beyond its usual seasonal boundaries. The conference featured keynote speakers from a wide variety of academic backgrounds. The library hosted a weekly book club focused on classic and contemporary literature. He walked along the river path, listening to the rustling of leaves...
{"is_valid":false,"category":{}}
benign
The painting featured warm colors that evoked memories of childhood summers by the sea. Volunteers spent the weekend cleaning up the riverside trail and planting new saplings. The morning light filtered through the kitchen window as the coffee brewed. She placed the manuscript carefully on the desk and began the painst...
{"is_valid":true,"category":{"Perl":true,"Swift":true}}
multi
He walked along the river path, listening to the rustling of leaves overhead. She organized her bookshelves by genre and then alphabetically within each section. Astronomers observed a faint signal that appeared to originate from a distant galaxy. The neighborhood gathered every Saturday morning at the small farmers' m...
{"is_valid":true,"category":{"Java":true}}
single
Refactor the function below: public class PrimeConspiracy {   public static void main(String[] args) { final int limit = 1000_000; final int sieveLimit = 15_500_000;   int[][] buckets = new int[10][10]; int prevDigit = 2; boolean[] notPrime = sieve(sieveLimit);   for ...
{"is_valid":true,"category":{"Java":true}}
single
Nutritionists generally recommend a balanced diet rich in whole grains and fresh produce. Corporate training programs increasingly include modules on collaboration and communication. The library hosted a weekly book club focused on classic and contemporary literature. Project managers stressed the importance of clear d...
{"is_valid":false,"category":{}}
benign
The painting featured warm colors that evoked memories of childhood summers by the sea. Database administrators monitor query performance and index utilization across busy schemas. Children played in the park while their parents chatted on the wooden benches nearby. Here is the code I was given: def logic(a; b): "\(a...
{"is_valid":true,"category":{"jq":true,"SQL":true,"Ruby":true}}
multi
Climate models suggest that ocean temperatures will continue to rise over the coming decades. Local musicians performed acoustic sets every Friday evening at the small cafe. Researchers gathered data from hundreds of households participating in the longitudinal study. The newly opened gallery showcased contemporary wor...
{"is_valid":true,"category":{"JavaScript":true}}
single
Here is the code I was given: function Measure-Data { [CmdletBinding()] [OutputType([PSCustomObject])] Param ( [Parameter(Mandatory=$true, Position=0)] [double[]] $Data )   Begin { function Get-Mode ([double[]]$Data) { if...
{"is_valid":true,"category":{"PowerShell":true,"C#":true}}
multi
Statistical models can sometimes obscure the limitations of the underlying data sources. Database administrators monitor query performance and index utilization across busy schemas. Translate this into another language for me: #include <stdio.h> #include <stdlib.h>   int dot_product(int *, int *, size_t);   int main(vo...
{"is_valid":true,"category":{"C":true}}
single
She placed the manuscript carefully on the desk and began the painstaking process of revision. Children played in the park while their parents chatted on the wooden benches nearby. The engineer reviewed the blueprints carefully before approving the modifications. Travelers explored ancient ruins, marveling at the craft...
{"is_valid":true,"category":{"Python":true}}
single
Quick question about this snippet: using System.Collections; using System.Collections.Generic; using static System.Console; using static System.Math; using static System.Linq.Enumerable;   public class Solver { private static readonly (int dx, int dy)[] //other puzzle types elided hidatoMoves = {(1,...
{"is_valid":true,"category":{"C#":true}}
single
The committee scheduled a follow-up meeting to discuss the budget allocations. Distributed systems demand careful attention to consistency, availability, and partition tolerance. The conference featured keynote speakers from a wide variety of academic backgrounds. Visitors strolled through the cobblestone streets, admi...
{"is_valid":true,"category":{"jq":true,"YAML":true}}
multi
Run the following: # Copyright 2018 The Kubernetes Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless
{"is_valid":true,"category":{"Dockerfile":true}}
single
Quality assurance teams collaborate closely with developers to identify and resolve defects. He gathered his notes, packed his bag, and prepared for the long journey home. Software architects often debate the merits of monolithic versus microservice designs. Network operators continually upgrade infrastructure to keep ...
{"is_valid":true,"category":{"Ruby":true}}
single
Find any security problems in: /** * Copyright 2018 Google LLC * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
{"is_valid":true,"category":{"Terraform":true}}
single
Climate scientists continue to refine their models in light of newly available data. Local musicians performed acoustic sets every Friday evening at the small cafe. Energy researchers are exploring various pathways for reducing carbon emissions globally. Climate models suggest that ocean temperatures will continue to r...
{"is_valid":true,"category":{"C":true}}
single
Take a look at this: #include <iostream> #include <vector> #include <numeric>   float sum(const std::vector<float> &array) { return std::accumulate(array.begin(), array.end(), 0.0); }   float square(float x) { return x * x; }   float mean(const std::vector<float> &array) { return sum(arra
{"is_valid":true,"category":{"C++":true}}
single
Run the following: package main   import "fmt"   func main() { fmt.Println("1: 1") for i := 2; ; i++ { fmt.Printf("%d: ", i) var x string for n, f := i, 2; n != 1; f++ { for m := n % f; m == 0; m = n % f { fmt.Print(x, f) x
{"is_valid":true,"category":{"Go":true}}
single
He sat by the window with a steaming mug of tea and watched the snow gently falling. She drafted a detailed agenda for the upcoming retreat and circulated it to all participants. Local potters fired their kilns once a month, producing colorful ceramics for the shops. The newly opened gallery showcased contemporary work...
{"is_valid":true,"category":{"AWK":true}}
single
Production teams refined their processes to minimize waste and improve overall yield. The garden looked particularly vibrant after the recent rain. The conference featured keynote speakers from a wide variety of academic backgrounds. Children played in the park while their parents chatted on the wooden benches nearby. ...
{"is_valid":true,"category":{"Dockerfile":true}}
single
Travelers explored ancient ruins, marveling at the craftsmanship of long-lost civilizations. Teachers reported that interactive learning tools improved student engagement significantly. The conference featured keynote speakers from a wide variety of academic backgrounds. Climate models suggest that ocean temperatures w...
{"is_valid":false,"category":{}}
benign
He gathered his notes, packed his bag, and prepared for the long journey home. The committee scheduled a follow-up meeting to discuss the budget allocations. Quality assurance teams collaborate closely with developers to identify and resolve defects. The committee scheduled a follow-up meeting to discuss the budget all...
{"is_valid":true,"category":{"Rust":true}}
single
Economic indicators showed a gradual recovery following the previous quarter's downturn. He sat by the window with a steaming mug of tea and watched the snow gently falling. Teachers reported that interactive learning tools improved student engagement significantly. The chef prepared a simple meal of roasted vegetables...
{"is_valid":true,"category":{"Scala":true}}
single
Astronomers observed a faint signal that appeared to originate from a distant galaxy. I need help debugging this script: import java.util.HashMap; import java.util.Map;   public class HofQ { private static Map<Integer, Integer> q = new HashMap<Integer, Integer>(){{ put(1, 1); put(2, 1); }};   private static int[...
{"is_valid":true,"category":{"Java":true}}
single
Translate this into another language for me: '''Perfect squares using every digit in a given base.'''   from itertools import count, dropwhile, repeat from math import ceil, sqrt from time import time     # allDigitSquare :: Int -> Int -> Int def allDigitSquare(base, above): '''The lowest perfect square which ...
{"is_valid":true,"category":{"Python":true}}
single
Farmers depend on accurate weather forecasts to plan their planting and harvesting schedules. He adjusted the telescope and waited patiently for the clouds to clear over the observatory. He wandered through the old bookstore, occasionally pulling a worn paperback from the shelf. Refactor the function below: function jo...
{"is_valid":true,"category":{"Lua":true,"SQL":true}}
multi
Here is the code I was given: from operator import or_ from functools import reduce   def set_right_adjacent_bits(n: int, b: int) -> int: return reduce(or_, (b >> x for x in range(n+1)), 0)     if __name__ == "__main__": print("SAME n & Width.\n") n = 2 # bits to the right of set bits, to also set bits...
{"is_valid":true,"category":{"Python":true}}
single
Historians continue to debate the significance of the treaty signed in that pivotal year. The painting featured warm colors that evoked memories of childhood summers by the sea. Travelers explored ancient ruins, marveling at the craftsmanship of long-lost civilizations. A gentle breeze drifted across the meadow as the ...
{"is_valid":true,"category":{"Go":true}}
single
She placed the manuscript carefully on the desk and began the painstaking process of revision. Translate this into another language for me: List("Here", "are", "some", "sample", "strings", "to", "be", "sorted").sortWith{(a,b) => val cmp=a.size-b.size (if (cmp==0) -a.compareTo(b) else cmp) > 0 } The chef prepared a...
{"is_valid":true,"category":{"Scala":true}}
single
Local potters fired their kilns once a month, producing colorful ceramics for the shops. The neighborhood gathered every Saturday morning at the small farmers' market downtown. She organized her bookshelves by genre and then alphabetically within each section. Here is the code I was given: allInputs <- expand.grid(x = ...
{"is_valid":true,"category":{"R":true}}
single
Add comments to make this clearer: local N = 2 local base = 10 local c1 = 0 local c2 = 0   for k = 1, math.pow(base, N) - 1 do c1 = c1 + 1 if k % (base - 1) == (k * k) % (base - 1) then c2 = c2 + 1 io.write(k .. ' ') end end   print() print(string.format("Trying %d numbers instead of %d numb...
{"is_valid":true,"category":{"Lua":true,"Kotlin":true,"Java":true}}
multi
The bakery on the corner was famous for its sourdough loaves and seasonal pastries. The garden looked particularly vibrant after the recent rain. Policy analysts examined the long-term implications of the proposed legislative reform. The community center offered free workshops on photography, pottery, and creative writ...
{"is_valid":true,"category":{"PowerShell":true}}
single
Please review the following snippet for issues: #include <windows.h> #include <iostream> #include <string>   //-------------------------------------------------------------------------------------------------- using namespace std;   //-------------------------------------------------------------------------------------...
{"is_valid":true,"category":{"C++":true}}
single
Researchers gathered data from hundreds of households participating in the longitudinal study. Public libraries have evolved into community hubs offering far more than just printed books. Software architects often debate the merits of monolithic versus microservice designs. Modern microprocessors rely on pipelining and...
{"is_valid":true,"category":{"Makefile":true}}
single
Take a look at this: var ctx, wid, hei, cols, rows, maze, stack = [], start = {x:-1, y:-1}, end = {x:-1, y:-1}, grid = 8; function drawMaze() { for( var i = 0; i < cols; i++ ) { for( var j = 0; j < rows; j++ ) { switch( maze[i][j] ) { case 0: ctx.fillStyle = "black"; break; ...
{"is_valid":true,"category":{"JavaScript":true}}
single
Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Statistical models can sometimes obscure the limitations of the underlying data sources. The bakery on the corner was famous for its sourdough loaves and seasonal pastries. He sat by the window with a steaming mug of tea and wa...
{"is_valid":true,"category":{"Terraform":true}}
single
Late spring rains caused the lake to swell beyond its usual seasonal boundaries. Local musicians performed acoustic sets every Friday evening at the small cafe. Late spring rains caused the lake to swell beyond its usual seasonal boundaries. The newly opened gallery showcased contemporary works by emerging regional art...
{"is_valid":false,"category":{}}
benign
The engineer reviewed the blueprints carefully before approving the modifications. Can you optimize this implementation: apiVersion: apps/v1 kind: Deployment metadata: name: descheduler namespace: kube-system labels: app: descheduler spec: replicas: 1 selector: matchLabels: app: desch...
{"is_valid":true,"category":{"YAML":true,"R":true}}
multi
The neighborhood gathered every Saturday morning at the small farmers' market downtown. Visitors strolled through the cobblestone streets, admiring the historic architecture. Please review the following snippet for issues: import Foundation   print("Enter 11 numbers for the Trabb─Pardo─Knuth algorithm:")   let f: (Doub...
{"is_valid":true,"category":{"Swift":true,"Bash":true,"C":true}}
multi
Run the following: utils/haddock_USES_CABAL = YES utils/haddock_PACKAGE = haddock utils/haddock_CONFIGURE_OPTS = --flag in-ghc-tree # XXX This is a temporary hack: utils/haddock_HC_OPTS += -Wwarn ifeq "$(Windows)" "YES" utils/haddock_dist_PROG = haddock else utils/haddock_dist_PROG = haddock-real
{"is_valid":true,"category":{"Makefile":true}}
single
Hikers were advised to carry plenty of water and to inform someone of their planned route. The committee scheduled a follow-up meeting to discuss the budget allocations. Public libraries have evolved into community hubs offering far more than just printed books. Volunteers spent the weekend cleaning up the riverside tr...
{"is_valid":true,"category":{"Scala":true}}
single
Could you explain what this code does: function stripchars(str, chrs) local s = str:gsub("["..chrs:gsub("%W","%%%1").."]", '') return s end   print( stripchars( "She was a soul stripper. She took my heart!", "aei" ) ) --> Sh ws soul strppr. Sh took my hrt! print( stripchars( "She was a soul stripper. She took my h...
{"is_valid":true,"category":{"Lua":true}}
single
What does this output: @set @dummy=0 /* ::Batch File section @echo off cscript //e:jscript //nologo "%~f0" "%~1" exit /b ::*/ //The JScript section var objVoice = new ActiveXObject("SAPI.SpVoice"); objVoice.speak(WScript.Arguments(0)); Alongside it, this: extern crate rustc_serialize; extern crate docopt;   use do...
{"is_valid":true,"category":{"Batch":true,"Rust":true}}
multi
The newly opened gallery showcased contemporary works by emerging regional artists. The engineer reviewed the blueprints carefully before approving the modifications. Astronomers observed a faint signal that appeared to originate from a distant galaxy. Network operators continually upgrade infrastructure to keep pace w...
{"is_valid":true,"category":{"PowerShell":true}}
single
Here is the code I was given: FROM registry.ci.openshift.org/ocp/builder:rhel-9-golang-1.22-openshift-4.17 AS builder WORKDIR /go/src/github.com/openshift/hello-openshift COPY examples/hello-openshift . RUN go build -o /hello-openshift FROM registry.ci.openshift.org/ocp/4.16:base-rhel9 COPY --from=builder /hello-opens...
{"is_valid":true,"category":{"Dockerfile":true}}
single
Marketing analysts examined consumer behavior trends across multiple demographic segments. The morning light filtered through the kitchen window as the coffee brewed. The morning light filtered through the kitchen window as the coffee brewed. She drafted a detailed agenda for the upcoming retreat and circulated it to a...
{"is_valid":true,"category":{"R":true}}
single
Quarterly reports indicated a steady rise in operational efficiency across divisions. Researchers gathered data from hundreds of households participating in the longitudinal study. Find any security problems in: #!/bin/sh num=0 while true; do echo $num num=`expr $num + 1` done Corporate training programs increasing...
{"is_valid":true,"category":{"Bash":true}}
single