prompt large_stringlengths 150 7.97k | target large_stringlengths 32 83 | kind large_stringclasses 3
values |
|---|---|---|
He adjusted the telescope and waited patiently for the clouds to clear over the observatory. Local potters fired their kilns once a month, producing colorful ceramics for the shops. Project managers stressed the importance of clear documentation throughout the cycle. The technology conference attracted engineers, desig... | {"is_valid":true,"category":{"Go":true}} | single |
The conference featured keynote speakers from a wide variety of academic backgrounds. Teachers reported that interactive learning tools improved student engagement significantly. Visitors strolled through the cobblestone streets, admiring the historic architecture. The community center offered free workshops on photogr... | {"is_valid":false,"category":{}} | benign |
Farmers depend on accurate weather forecasts to plan their planting and harvesting schedules. Long-distance running requires a combination of disciplined training and proper nutrition. Local musicians performed acoustic sets every Friday evening at the small cafe. She enjoyed reading historical novels that transported ... | {"is_valid":false,"category":{}} | benign |
Engineering teams often adopt iterative methodologies to manage complex software projects. What does this output:
// Arrays are typed in Swift, however, using the Any object we can add any type. Swift does not support fixed length arrays
var anyArray = [Any]()
anyArray.append("foo") // Adding to an Array
anyArray.appen... | {"is_valid":true,"category":{"Swift":true}} | single |
I need help debugging this script:
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
double int_leftrect(double from, double to, double n, double (*func)())
{
double h = (to-from)/n;
double sum = 0.0, x;
for(x=from; x <= (to-h); x += h)
sum += func(x);
return h*sum;
}
double int_rightrect(d... | {"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. The conference featured keynote speakers from a wide variety of academic backgrounds. The morning light filtered through the kitchen window as th... | {"is_valid":false,"category":{}} | benign |
The morning light filtered through the kitchen window as the coffee brewed. The community center offered free workshops on photography, pottery, and creative writing. Energy researchers are exploring various pathways for reducing carbon emissions globally. Network operators continually upgrade infrastructure to keep pa... | {"is_valid":true,"category":{"Kotlin":true,"AWK":true}} | multi |
Local potters fired their kilns once a month, producing colorful ceramics for the shops. He walked along the river path, listening to the rustling of leaves overhead. Hikers were advised to carry plenty of water and to inform someone of their planned route. Network operators continually upgrade infrastructure to keep p... | {"is_valid":true,"category":{"Makefile":true}} | single |
Find any security problems in:
using OpenTK;
using OpenTK.Graphics;
namespace OpenGLTest
{
class Program
{
static void Main(string[] args)
{
//Create the OpenGL window
GameWindow window = new GameWindow(640, 480, GraphicsMode.Default, "OpenGL Example");
GL.M... | {"is_valid":true,"category":{"C#":true}} | single |
Run the following:
// version 1.0.6
operator fun <T> List<T>.compareTo(other: List<T>): Int
where T: Comparable<T>, T: Number {
for (i in 0 until this.size) {
if (other.size == i) return 1
when {
this[i] < other[i] -> return -1
this[i] > other[i] -> return 1
}
... | {"is_valid":true,"category":{"Kotlin":true}} | single |
Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Could you explain what this code does:
CREATE TABLE competition (country VARCHAR, competition_type VARCHAR);
SELECT country FROM competition WHERE competition_type = 'Friendly' INTERSECT SELECT country FROM competition WHERE co... | {"is_valid":true,"category":{"SQL":true}} | single |
He sat by the window with a steaming mug of tea and watched the snow gently falling. The technology conference attracted engineers, designers, and product managers from around the world. Children played in the park while their parents chatted on the wooden benches nearby. Quarterly reports indicated a steady rise in op... | {"is_valid":false,"category":{}} | benign |
Software architects often debate the merits of monolithic versus microservice designs. Refactor the function below:
lua -e 'for x in io.lines() do print(x) end' | {"is_valid":true,"category":{"Lua":true}} | single |
Database administrators monitor query performance and index utilization across busy schemas. The chef prepared a simple meal of roasted vegetables, fresh bread, and a light vinaigrette. The painting featured warm colors that evoked memories of childhood summers by the sea. Travelers explored ancient ruins, marveling at... | {"is_valid":true,"category":{"Lua":true}} | single |
He gathered his notes, packed his bag, and prepared for the long journey home. Researchers gathered data from hundreds of households participating in the longitudinal study. Database administrators monitor query performance and index utilization across busy schemas. Travelers explored ancient ruins, marveling at the cr... | {"is_valid":false,"category":{}} | benign |
Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. The painting featured warm colors that evoked memories of childhood summers by the sea. Climate scientists continue to refine their models in light of newly available data. He wandered through the old bookstore, occasionally pu... | {"is_valid":true,"category":{"YAML":true}} | single |
Take a look at this:
# syntax: GAWK -f STEM-AND-LEAF_PLOT.AWK
#
# sorting:
# PROCINFO["sorted_in"] is used by GAWK
# SORTTYPE is used by Thompson Automation's TAWK
#
BEGIN {
data = "12 127 28 42 39 113 42 18 44 118 44 37 113 124 37 48 127 36 29 31 " \
"125 139 131 115 105 132 104 123 35 113 122 42 117 119 5... | {"is_valid":true,"category":{"AWK":true}} | single |
Translate this into another language for me:
public class FourIsMagic {
public static void main(String[] args) {
for ( long n : new long[] {6, 60, 89, 300, 670, 2000, 2467, 20000, 24500,200000, 230000, 246571, 2300000, 2465712, 20000000, 24657123, 230000000, 245000000, -246570000, 123456789712345l, 877777... | {"is_valid":true,"category":{"Java":true}} | single |
Travelers explored ancient ruins, marveling at the craftsmanship of long-lost civilizations. Here is the code I was given:
def church(f; $x; $m):
if $m == 0 then .
elif $m == 1 then $x|f
else church(f; $x; $m - 1)
end; | {"is_valid":true,"category":{"jq":true}} | single |
Find any security problems in:
require "prime"
limit = 1_000_000
puts "First found longest run of ascending prime gaps up to #{limit}:"
p Prime.each(limit).each_cons(2).chunk_while{|(i1,i2), (j1,j2)| j1-i1 < j2-i2 }.max_by(&:size).flatten.uniq
puts "\nFirst found longest run of descending prime gaps up to #{limit}:... | {"is_valid":true,"category":{"Ruby":true}} | single |
Researchers have been studying migration patterns of monarch butterflies for years. Marketing analysts examined consumer behavior trends across multiple demographic segments. Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Production teams refined their processes to minimize... | {"is_valid":true,"category":{"SQL":true}} | single |
Take a look at this:
@a = ('It is certain', 'It is decidedly so', 'Without a doubt', 'Yes, definitely',
'You may rely on it', 'As I see it, yes', 'Most likely', 'Outlook good',
'Signs point to yes', 'Yes', 'Reply hazy, try again', 'Ask again later',
'Better not tell you now', 'Cannot predict now', 'Concentrate and a... | {"is_valid":true,"category":{"Perl":true}} | single |
The library hosted a weekly book club focused on classic and contemporary literature. Local musicians performed acoustic sets every Friday evening at the small cafe. Production teams refined their processes to minimize waste and improve overall yield. Astronomers observed a faint signal that appeared to originate from ... | {"is_valid":false,"category":{}} | benign |
What does this output:
# syntax: GAWK -f RECAMANS_SEQUENCE.AWK
# converted from Microsoft Small Basic
BEGIN {
found_dup = 0
n = -1
do {
n++
ap = a[n-1] + n
if (a[n-1] <= n) {
a[n] = ap
b[ap] = 1
}
else {
am = a[n-1] - n
if (b[am] == 1) {
... | {"is_valid":true,"category":{"AWK":true}} | single |
I need help debugging this script:
@echo off
call:horners a:-19 b:7 c:-4 d:6 x:3
call:horners x:3 a:-19 c:-4 d:6 b:7
pause>nul
exit /b
:horners
setlocal enabledelayedexpansion
set a=0
set b=0
set c=0
set d=0
set x=0
for %%i in (%*) do (
for /f "tokens=1,2 delims=:" %%j in ("%%i") do (
set %%j=%%k
)
)
set ... | {"is_valid":true,"category":{"Batch":true,"Scala":true,"PowerShell":true}} | multi |
Translate this into another language for me:
import java.util.*;
public class KnightsTour {
private final static int base = 12;
private final static int[][] moves = {{1,-2},{2,-1},{2,1},{1,2},{-1,2},
{-2,1},{-2,-1},{-1,-2}};
private static int[][] grid;
private static int total;
public s... | {"is_valid":true,"category":{"Java":true}} | single |
Could you explain what this code does:
################################################################
# project name
################################################################
# This name is used for the distribution tar file.
project_name := ShellCorretta
####################################################... | {"is_valid":true,"category":{"Makefile":true}} | single |
Quick question about this snippet:
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2... | {"is_valid":true,"category":{"Dockerfile":true}} | single |
The classroom hummed with quiet conversation as students worked through practice problems. The bakery on the corner was famous for its sourdough loaves and seasonal pastries. Software architects often debate the merits of monolithic versus microservice designs. Software architects often debate the merits of monolithic ... | {"is_valid":true,"category":{"Go":true}} | single |
She placed the manuscript carefully on the desk and began the painstaking process of revision. Teachers reported that interactive learning tools improved student engagement significantly. Quick question about this snippet:
CREATE TABLE wedding (church_id VARCHAR); CREATE TABLE church (name VARCHAR, church_id VARCHAR);
... | {"is_valid":true,"category":{"SQL":true}} | single |
Please review the following snippet for issues:
#!/bin/sh
pathlist='/home/user1/tmp/coverage/test
/home/user1/tmp/covert/operator
/home/user1/tmp/coven/members'
i=2
while [ $i -lt 100 ]
do
path=`echo "$pathlist" | cut -f1-$i -d/ | uniq -d`
if [ -z "$path" ]
then
echo $prev_path
break
else
p... | {"is_valid":true,"category":{"Bash":true}} | single |
He gathered his notes, packed his bag, and prepared for the long journey home. Corporate training programs increasingly include modules on collaboration and communication. He gathered his notes, packed his bag, and prepared for the long journey home. Historians continue to debate the significance of the treaty signed i... | {"is_valid":true,"category":{"Rust":true}} | single |
He gathered his notes, packed his bag, and prepared for the long journey home. Astronomers observed a faint signal that appeared to originate from a distant galaxy. The committee scheduled a follow-up meeting to discuss the budget allocations. Visitors strolled through the cobblestone streets, admiring the historic arc... | {"is_valid":true,"category":{"JavaScript":true}} | single |
She organized her bookshelves by genre and then alphabetically within each section. Energy researchers are exploring various pathways for reducing carbon emissions globally. The neighborhood gathered every Saturday morning at the small farmers' market downtown. Please review the following snippet for issues:
def zNum( ... | {"is_valid":true,"category":{"Scala":true}} | single |
The chef prepared a simple meal of roasted vegetables, fresh bread, and a light vinaigrette. Production teams refined their processes to minimize waste and improve overall yield. Researchers gathered data from hundreds of households participating in the longitudinal study. Astronomers observed a faint signal that appea... | {"is_valid":true,"category":{"JavaScript":true}} | single |
Marketing analysts examined consumer behavior trends across multiple demographic segments. Production teams refined their processes to minimize waste and improve overall yield. He sat by the window with a steaming mug of tea and watched the snow gently falling. The technology conference attracted engineers, designers, ... | {"is_valid":false,"category":{}} | benign |
Teachers reported that interactive learning tools improved student engagement significantly. A gentle breeze drifted across the meadow as the sun began to dip below the horizon. The garden looked particularly vibrant after the recent rain. He wandered through the old bookstore, occasionally pulling a worn paperback fro... | {"is_valid":true,"category":{"Terraform":true}} | single |
She drafted a detailed agenda for the upcoming retreat and circulated it to all participants. Policy analysts examined the long-term implications of the proposed legislative reform. She organized her bookshelves by genre and then alphabetically within each section. I need help debugging this script:
function squareFree... | {"is_valid":true,"category":{"Lua":true}} | single |
Visitors strolled through the cobblestone streets, admiring the historic architecture. The garden looked particularly vibrant after the recent rain. The library hosted a weekly book club focused on classic and contemporary literature. Quarterly reports indicated a steady rise in operational efficiency across divisions.... | {"is_valid":true,"category":{"Perl":true,"AWK":true}} | multi |
Teachers reported that interactive learning tools improved student engagement significantly. Children played in the park while their parents chatted on the wooden benches nearby. The neighborhood gathered every Saturday morning at the small farmers' market downtown. He gathered his notes, packed his bag, and prepared f... | {"is_valid":true,"category":{"Batch":true}} | single |
Economic indicators showed a gradual recovery following the previous quarter's downturn. Travelers explored ancient ruins, marveling at the craftsmanship of long-lost civilizations. Add comments to make this clearer:
public interface Camera{
//functions here with no definition...
//ex:
//public void takePictur... | {"is_valid":true,"category":{"Java":true}} | single |
Policy analysts examined the long-term implications of the proposed legislative reform. Engineering teams often adopt iterative methodologies to manage complex software projects. Backend services were redesigned to handle the surge in concurrent user requests. Hikers were advised to carry plenty of water and to inform ... | {"is_valid":true,"category":{"Go":true}} | single |
She placed the manuscript carefully on the desk and began the painstaking process of revision. Network operators continually upgrade infrastructure to keep pace with growing demand. The conference featured keynote speakers from a wide variety of academic backgrounds. Project managers stressed the importance of clear do... | {"is_valid":true,"category":{"R":true}} | single |
Find any security problems in:
#include<stdlib.h>
#include<stdio.h>
#include<math.h>
int p[512];
double fade(double t) { return t * t * t * (t * (t * 6 - 15) + 10); }
double lerp(double t, double a, double b) { return a + t * (b - a); }
double grad(int hash, double x, double y, double z) {
int h = hash & 15; ... | {"is_valid":true,"category":{"C":true,"Scala":true}} | multi |
Project managers stressed the importance of clear documentation throughout the cycle. Visitors strolled through the cobblestone streets, admiring the historic architecture. Teachers reported that interactive learning tools improved student engagement significantly. Astronomers observed a faint signal that appeared to o... | {"is_valid":true,"category":{"SQL":true}} | single |
Local potters fired their kilns once a month, producing colorful ceramics for the shops. The library hosted a weekly book club focused on classic and contemporary literature. Policy analysts examined the long-term implications of the proposed legislative reform. Policy analysts examined the long-term implications of th... | {"is_valid":true,"category":{"Dockerfile":true}} | single |
Translate this into another language for me:
// version 1.1.2
class PointF(val x: Float, val y: Float) {
override fun toString() = "{$x, $y}"
}
class LineF(val s: PointF, val e: PointF)
fun findIntersection(l1: LineF, l2: LineF): PointF {
val a1 = l1.e.y - l1.s.y
val b1 = l1.s.x - l1.e.x
val c1 = ... | {"is_valid":true,"category":{"Kotlin":true}} | single |
The classroom hummed with quiet conversation as students worked through practice problems. Researchers have been studying migration patterns of monarch butterflies for years. Researchers gathered data from hundreds of households participating in the longitudinal study. The garden looked particularly vibrant after the r... | {"is_valid":true,"category":{"Dockerfile":true}} | single |
The library hosted a weekly book club focused on classic and contemporary literature. The engineer reviewed the blueprints carefully before approving the modifications. Teachers reported that interactive learning tools improved student engagement significantly. Software architects often debate the merits of monolithic ... | {"is_valid":false,"category":{}} | benign |
Software architects often debate the merits of monolithic versus microservice designs. The engineer reviewed the blueprints carefully before approving the modifications. Climate scientists continue to refine their models in light of newly available data. Policy analysts examined the long-term implications of the propos... | {"is_valid":true,"category":{"JavaScript":true}} | single |
I copied this from the docs:
using System;
namespace CantorSet {
class Program {
const int WIDTH = 81;
const int HEIGHT = 5;
private static char[,] lines = new char[HEIGHT, WIDTH];
static Program() {
for (int i = 0; i < HEIGHT; i++) {
for (int j = 0; j... | {"is_valid":true,"category":{"C#":true}} | single |
Quick question about this snippet:
extension BinaryInteger {
@inlinable
public func egyptianDivide(by divisor: Self) -> (quo: Self, rem: Self) {
let table =
(0...).lazy
.map({i -> (Self, Self) in
let power = Self(2).power(Self(i))
return (power, power * divisor)
})
... | {"is_valid":true,"category":{"Swift":true}} | single |
Find any security problems in:
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace SokobanSolver
{
public class SokobanSolver
{
private class Board
{
public string Cur { get; internal set; }
public string Sol { get; internal set; }
... | {"is_valid":true,"category":{"C#":true}} | single |
The conference featured keynote speakers from a wide variety of academic backgrounds. The morning light filtered through the kitchen window as the coffee brewed. Could you explain what this code does:
$ expr 700 - 1
699
$ expr 0700 - 01
699
We also have this other snippet:
# Licensed to the Apache Software Foundation ... | {"is_valid":true,"category":{"Bash":true,"Dockerfile":true}} | multi |
Teachers reported that interactive learning tools improved student engagement significantly. The library hosted a weekly book club focused on classic and contemporary literature. Can you optimize this implementation:
# Convert a quarter-imaginary base value (as a string) into a base 10 Gaussian integer.
def base2i_de... | {"is_valid":true,"category":{"Ruby":true}} | single |
Engineering teams often adopt iterative methodologies to manage complex software projects. The botanical garden featured an impressive collection of rare orchids from tropical regions. Researchers gathered data from hundreds of households participating in the longitudinal study. A gentle breeze drifted across the meado... | {"is_valid":true,"category":{"Bash":true,"Perl":true}} | multi |
He wandered through the old bookstore, occasionally pulling a worn paperback from the shelf. Researchers gathered data from hundreds of households participating in the longitudinal study. The painting featured warm colors that evoked memories of childhood summers by the sea. Network operators continually upgrade infras... | {"is_valid":true,"category":{"Makefile":true}} | single |
The classroom hummed with quiet conversation as students worked through practice problems. Travelers explored ancient ruins, marveling at the craftsmanship of long-lost civilizations. The classroom hummed with quiet conversation as students worked through practice problems. Energy researchers are exploring various path... | {"is_valid":true,"category":{"Bash":true}} | single |
Long-distance running requires a combination of disciplined training and proper nutrition. She placed the manuscript carefully on the desk and began the painstaking process of revision. A gentle breeze drifted across the meadow as the sun began to dip below the horizon. Public libraries have evolved into community hubs... | {"is_valid":true,"category":{"Java":true}} | single |
Here is the code I was given:
import java.net.URI
import java.net.http.HttpClient
import java.net.http.HttpRequest
import java.net.http.HttpResponse
import java.util.regex.Pattern
import java.util.stream.Collectors
const val BASE = "http://rosettacode.org"
fun main() {
val client = HttpClient.newBuilder().build... | {"is_valid":true,"category":{"Kotlin":true}} | single |
I need help debugging this script:
// version 1.0.5-2
fun meanAngle(angles: DoubleArray): Double {
val sinSum = angles.sumByDouble { Math.sin(it * Math.PI / 180.0) }
val cosSum = angles.sumByDouble { Math.cos(it * Math.PI / 180.0) }
return Math.atan2(sinSum / angles.size, cosSum / angles.size) * 180.0 /... | {"is_valid":true,"category":{"Kotlin":true}} | single |
Local potters fired their kilns once a month, producing colorful ceramics for the shops. Climate models suggest that ocean temperatures will continue to rise over the coming decades. The neighborhood gathered every Saturday morning at the small farmers' market downtown. Marketing analysts examined consumer behavior tre... | {"is_valid":true,"category":{"AWK":true}} | single |
Network operators continually upgrade infrastructure to keep pace with growing demand. The newly opened gallery showcased contemporary works by emerging regional artists. She drafted a detailed agenda for the upcoming retreat and circulated it to all participants. The chef prepared a simple meal of roasted vegetables, ... | {"is_valid":true,"category":{"YAML":true}} | single |
The community center offered free workshops on photography, pottery, and creative writing. Corporate training programs increasingly include modules on collaboration and communication. She organized her bookshelves by genre and then alphabetically within each section. She drafted a detailed agenda for the upcoming retre... | {"is_valid":true,"category":{"JavaScript":true}} | single |
The conference featured keynote speakers from a wide variety of academic backgrounds. Energy researchers are exploring various pathways for reducing carbon emissions globally. Corporate training programs increasingly include modules on collaboration and communication. Software architects often debate the merits of mono... | {"is_valid":true,"category":{"Scala":true,"Batch":true,"Dockerfile":true}} | multi |
The newly opened gallery showcased contemporary works by emerging regional artists. Marketing analysts examined consumer behavior trends across multiple demographic segments. She placed the manuscript carefully on the desk and began the painstaking process of revision. She enjoyed reading historical novels that transpo... | {"is_valid":true,"category":{"Perl":true}} | single |
Economic indicators showed a gradual recovery following the previous quarter's downturn. Travelers explored ancient ruins, marveling at the craftsmanship of long-lost civilizations. Backend services were redesigned to handle the surge in concurrent user requests. Engineering teams often adopt iterative methodologies to... | {"is_valid":true,"category":{"Bash":true}} | single |
The neighborhood gathered every Saturday morning at the small farmers' market downtown. 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. The neighborhood gathered every Saturday mo... | {"is_valid":true,"category":{"Rust":true}} | single |
Corporate training programs increasingly include modules on collaboration and communication. Take a look at this:
fn strip_comment<'a>(input: &'a str, markers: &[char]) -> &'a str {
input
.find(markers)
.map(|idx| &input[..idx])
.unwrap_or(input)
.trim()
}
fn main() {
println!(... | {"is_valid":true,"category":{"Rust":true,"C++":true}} | multi |
The committee scheduled a follow-up meeting to discuss the budget allocations. She enjoyed reading historical novels that transported her to far away places. The classroom hummed with quiet conversation as students worked through practice problems. Historians continue to debate the significance of the treaty signed in ... | {"is_valid":true,"category":{"Kotlin":true}} | single |
The neighborhood gathered every Saturday morning at the small farmers' market downtown. Researchers gathered data from hundreds of households participating in the longitudinal study. Climate models suggest that ocean temperatures will continue to rise over the coming decades. Long-distance running requires a combinatio... | {"is_valid":true,"category":{"Kotlin":true,"Go":true}} | multi |
The library hosted a weekly book club focused on classic and contemporary literature. Hikers were advised to carry plenty of water and to inform someone of their planned route. Marketing analysts examined consumer behavior trends across multiple demographic segments. She drafted a detailed agenda for the upcoming retre... | {"is_valid":true,"category":{"PowerShell":true}} | single |
Production teams refined their processes to minimize waste and improve overall yield. Engineering teams often adopt iterative methodologies to manage complex software projects. A gentle breeze drifted across the meadow as the sun began to dip below the horizon. Quality assurance teams collaborate closely with developer... | {"is_valid":true,"category":{"Go":true,"R":true}} | multi |
Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Astronomers observed a faint signal that appeared to originate from a distant galaxy. Policy analysts examined the long-term implications of the proposed legislative reform. Engineering teams often adopt iterative methodologies... | {"is_valid":true,"category":{"Swift":true,"C#":true}} | multi |
Marketing analysts examined consumer behavior trends across multiple demographic segments. Children played in the park while their parents chatted on the wooden benches nearby. Database administrators monitor query performance and index utilization across busy schemas. Farmers depend on accurate weather forecasts to pl... | {"is_valid":true,"category":{"Rust":true}} | single |
Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Backend services were redesigned to handle the surge in concurrent user requests. Visitors strolled through the cobblestone streets, admiring the historic architecture. He gathered his notes, packed his bag, and prepared for th... | {"is_valid":true,"category":{"Java":true,"PowerShell":true}} | multi |
Run the following:
@echo off
setlocal enabledelayedexpansion
call:newdeck deck
echo new deck:
echo.
call:showcards deck
echo.
echo shuffling:
echo.
call:shuffle deck
call:showcards deck
echo.
echo dealing 5 cards to 4 players
call:deal deck 5 hand1 hand2 hand3 hand4
echo.
echo player 1 & call | {"is_valid":true,"category":{"Batch":true}} | single |
He adjusted the telescope and waited patiently for the clouds to clear over the observatory. Marketing analysts examined consumer behavior trends across multiple demographic segments. He adjusted the telescope and waited patiently for the clouds to clear over the observatory. Network operators continually upgrade infra... | {"is_valid":true,"category":{"Batch":true}} | single |
Public libraries have evolved into community hubs offering far more than just printed books. Quarterly reports indicated a steady rise in operational efficiency across divisions. Late spring rains caused the lake to swell beyond its usual seasonal boundaries. The conference featured keynote speakers from a wide variety... | {"is_valid":false,"category":{}} | benign |
Quick question about this snippet:
import java.util.Calendar
import java.text.SimpleDateFormat
object Fridays {
def lastFridayOfMonth(year:Int, month:Int)={
val cal=Calendar.getInstance
cal.set(Calendar.YEAR, year)
cal.set(Calendar.MONTH, month)
cal.set(Calendar.DAY_OF_WEEK, Calendar.FRIDAY) | {"is_valid":true,"category":{"Scala":true}} | single |
Statistical models can sometimes obscure the limitations of the underlying data sources. Here is the code I was given:
apiVersion: v1
kind: Service
metadata:
name: component-repository-service
namespace: oih-dev-ns
labels:
app: component-repository-service
spec:
type: NodePort
selector:
app: component... | {"is_valid":true,"category":{"YAML":true}} | single |
Climate scientists continue to refine their models in light of newly available data. Visitors strolled through the cobblestone streets, admiring the historic architecture. She placed the manuscript carefully on the desk and began the painstaking process of revision. He sat by the window with a steaming mug of tea and w... | {"is_valid":true,"category":{"Rust":true}} | single |
The newly opened gallery showcased contemporary works by emerging regional artists. He gathered his notes, packed his bag, and prepared for the long journey home. Here is the code I was given:
[hashtable]$mailMessage = @{
From = "weirdBoy@gmail.com"
To = "anudderBoy@YourDomain.com"
Cc = "daWaghBoss@YourDoma... | {"is_valid":true,"category":{"PowerShell":true}} | single |
Translate this into another language for me:
function distcheck(random_func, times, opts) {
if (opts === undefined) opts = {}
opts['delta'] = opts['delta'] || 2;
var count = {}, vals = [];
for (var i = 0; i < times; i++) {
var val = random_func();
if (! has_property(count, val)) {
... | {"is_valid":true,"category":{"JavaScript":true}} | single |
The committee scheduled a follow-up meeting to discuss the budget allocations. Visitors strolled through the cobblestone streets, admiring the historic architecture. Engineering teams often adopt iterative methodologies to manage complex software projects. Modern microprocessors rely on pipelining and out-of-order exec... | {"is_valid":true,"category":{"Terraform":true,"SQL":true}} | multi |
Network operators continually upgrade infrastructure to keep pace with growing demand. The neighborhood gathered every Saturday morning at the small farmers' market downtown. Local potters fired their kilns once a month, producing colorful ceramics for the shops. The committee scheduled a follow-up meeting to discuss t... | {"is_valid":true,"category":{"Lua":true}} | single |
Run the following:
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "Licen... | {"is_valid":true,"category":{"Dockerfile":true}} | single |
What does this output:
Windows PowerShell
Copyright (C) 2012 Microsoft Corporation. All rights reserved.
PS C:\Users\FransAdm> scala
Welcome to Scala version 2.10.1 (Java HotSpot(TM) 64-Bit Server VM, Java 1.7.0_25).
Type in expressions to have them evaluated.
Type :help for more information.
scala> // Immutable co... | {"is_valid":true,"category":{"Scala":true}} | single |
What does this output:
class T {
required init() { } // constructor used in polymorphic initialization must be "required"
func identify() {
println("I am a genuine T")
}
func copy() -> T {
let newObj : T = self.dynamicType() // call an appropriate constructor here
// then copy data into newObj as ap... | {"is_valid":true,"category":{"Swift":true}} | single |
The newly opened gallery showcased contemporary works by emerging regional artists. Run the following:
$i = 0
foreach ($s in $args) {
Write-Host Argument (++$i) is $s
} | {"is_valid":true,"category":{"PowerShell":true}} | single |
He adjusted the telescope and waited patiently for the clouds to clear over the observatory. Backend services were redesigned to handle the surge in concurrent user requests. The bakery on the corner was famous for its sourdough loaves and seasonal pastries. The classroom hummed with quiet conversation as students work... | {"is_valid":true,"category":{"Lua":true,"Dockerfile":true}} | multi |
The chef prepared a simple meal of roasted vegetables, fresh bread, and a light vinaigrette. Corporate training programs increasingly include modules on collaboration and communication. Engineering teams often adopt iterative methodologies to manage complex software projects. Production teams refined their processes to... | {"is_valid":true,"category":{"Kotlin":true}} | single |
Modern microprocessors rely on pipelining and out-of-order execution to maximize throughput. Nutritionists generally recommend a balanced diet rich in whole grains and fresh produce. Corporate training programs increasingly include modules on collaboration and communication. The morning light filtered through the kitch... | {"is_valid":false,"category":{}} | benign |
Database administrators monitor query performance and index utilization across busy schemas. Production teams refined their processes to minimize waste and improve overall yield. Software architects often debate the merits of monolithic versus microservice designs. The engineer reviewed the blueprints carefully before ... | {"is_valid":true,"category":{"YAML":true}} | single |
Find any security problems in:
namespace Algorithms
{
using System;
using System.Collections.Generic;
using System.Linq;
public class TopologicalSorter<ValueType>
{
private class Relations
{
public int Dependencies = 0;
public HashSet<ValueType> Dependents =... | {"is_valid":true,"category":{"C#":true}} | single |
Run the following:
# syntax: GAWK -f DRAW_A_CUBOID.AWK [-v x=?] [-v y=?] [-v z=?]
# example: GAWK -f DRAW_A_CUBOID.AWK -v x=12 -v y=4 -v z=6
# converted from VBSCRIPT
BEGIN {
init_sides()
draw_cuboid(2,3,4)
draw_cuboid(1,1,1)
draw_cuboid(6,2,1)
exit (errors == 0) ? 0 : 1
}
funct | {"is_valid":true,"category":{"AWK":true}} | single |
Hikers were advised to carry plenty of water and to inform someone of their planned route. He adjusted the telescope and waited patiently for the clouds to clear over the observatory. She organized her bookshelves by genre and then alphabetically within each section. Distributed systems demand careful attention to cons... | {"is_valid":false,"category":{}} | benign |
Refactor the function below:
using System;
using System.Collections.Generic;
using System.Numerics;
namespace TonelliShanks {
class Solution {
private readonly BigInteger root1, root2;
private readonly bool exists;
public Solution(BigInteger root1, BigInteger root2, bool exist | {"is_valid":true,"category":{"C#":true}} | single |
Translate this into another language for me:
#include <time.h>
#include <stdlib.h>
#include <vector>
#include <string>
#include <iostream>
class p15 {
public :
void play() {
bool p = true;
std::string a;
while( p ) {
createBrd();
while( !isDone() ) { drawBrd();getMove... | {"is_valid":true,"category":{"C++":true}} | single |
The painting featured warm colors that evoked memories of childhood summers by the sea. The committee scheduled a follow-up meeting to discuss the budget allocations. Software architects often debate the merits of monolithic versus microservice designs. The community center offered free workshops on photography, potter... | {"is_valid":true,"category":{"SQL":true}} | single |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.