Dataset Viewer
Auto-converted to Parquet Duplicate
instruction_seed
stringlengths
308
3.48k
source
stringclasses
1 value
embeddings
sequencelengths
1.02k
1.02k
mean_positive_score
float64
0.8
0.86
mean_negative_score
float64
0.74
0.8
difference_score
float64
0.05
0.07
Please write the following solution using ANSI C: Given the `root` of a binary search tree, a `target` value, and an integer `k`, return _the_ `k` _values in the BST that are closest to the_ `target`. You may return the answer in **any order**. You are **guaranteed** to have only one unique set of `k` values in the BS...
dolphin
[ 0.04389355331659317, 0.03993948549032211, -0.02810860238969326, -0.03249530494213104, 0.038448650389909744, -0.04505085572600365, -0.00916977971792221, 0.05777943506836891, 0.04499810189008713, -0.015468602068722248, 0.05059443414211273, 0.023778004571795464, -0.0327158197760582, -0.004328...
0.83789
0.783063
0.054826
Please write the following solution using Fortran: You are given an **even** number of people `numPeople` that stand around a circle and each person shakes hands with someone else so that there are `numPeople / 2` handshakes total. Return _the number of ways these handshakes could occur such that none of the handshake...
dolphin
[ 0.03850557282567024, 0.023423602804541588, -0.02990741655230522, -0.028611933812499046, 0.034784864634275436, -0.01494054589420557, -0.02361280843615532, 0.03228599205613136, 0.025252770632505417, -0.030585497617721558, 0.03074503131210804, 0.04386600852012634, -0.02079470269382, -0.037805...
0.835343
0.781007
0.054336
Please focus on the algorithm of this problem and provide code in c++: You are given an integer array `nums` and an integer `k`. In one operation, you can pick two numbers from the array whose sum equals `k` and remove them from the array. Return _the maximum number of operations you can perform on the array_. **Exa...
dolphin
[ 0.017415575683116913, 0.02492978237569332, -0.018511924892663956, -0.028420427814126015, 0.037036217749118805, -0.007742306683212519, -0.03202114254236221, 0.0997491106390953, 0.050243787467479706, -0.013050513342022896, 0.014106129296123981, 0.03148941323161125, -0.017573021352291107, -0....
0.841483
0.777792
0.063692
Please focus on the efficiency of this problem and provide code in c++: It is a sweltering summer day, and a boy wants to buy some ice cream bars. At the store, there are `n` ice cream bars. You are given an array `costs` of length `n`, where `costs[i]` is the price of the `ith` ice cream bar in coins. The boy initial...
dolphin
[ 0.032280802726745605, 0.029553484171628952, -0.02135959453880787, -0.01724984496831894, 0.0216530729085207, 0.00007412211562041193, -0.04569084569811821, 0.08754625916481018, 0.022115811705589294, -0.022261282429099083, 0.024312645196914673, 0.041278161108493805, -0.03219686076045036, -0.0...
0.843115
0.787056
0.05606
Please write the following solution using java: You are given an integer array `nums` with the following properties: * `nums.length == 2 * n`. * `nums` contains `n + 1` **unique** elements. * Exactly one element of `nums` is repeated `n` times. Return _the element that is repeated_ `n` _times_. **Example 1:** ...
dolphin
[ 0.027719812467694283, 0.025185799226164818, -0.028536077588796616, -0.026640797033905983, 0.03555656969547272, -0.024729356169700623, -0.030577117577195168, 0.06261889636516571, 0.016225386410951614, -0.006069356109946966, 0.02215413749217987, 0.01103300042450428, -0.027525093406438828, -0...
0.840698
0.768818
0.07188
Please write the following solution using Haskell: You are given an array `nums` of size `n` consisting of **distinct** integers from `1` to `n` and a positive integer `k`. Return _the number of non-empty subarrays in_ `nums` _that have a **median** equal to_ `k`. **Note**: * The median of an array is the **middle...
dolphin
[ 0.031225183978676796, 0.02333826571702957, -0.030455930158495903, -0.031063446775078773, 0.04603952169418335, -0.005643297452479601, -0.021075408905744553, 0.04624391719698906, 0.026996567845344543, -0.00829322636127472, 0.028502749279141426, 0.015733031556010246, -0.026369446888566017, -0...
0.833584
0.776441
0.057143
Please focus on the efficiency of this problem and provide code in java: You are given an integer array `rolls` of length `n` and an integer `k`. You roll a `k` sided dice numbered from `1` to `k`, `n` times, where the result of the `ith` roll is `rolls[i]`. Return _the length of the **shortest** sequence of rolls tha...
dolphin
[ 0.022912070155143738, 0.0334065742790699, -0.02365540899336338, -0.031682271510362625, 0.02172182686626911, -0.029681265354156494, -0.0243691299110651, 0.05240604281425476, 0.038485873490571976, -0.016672633588314056, 0.031492218375205994, 0.015817521139979362, -0.022376153618097305, 0.006...
0.845184
0.785316
0.059868
Please explain the following problem in detail and provide code in c++: Given a list of `dominoes`, `dominoes[i] = [a, b]` is **equivalent to** `dominoes[j] = [c, d]` if and only if either (`a == c` and `b == d`), or (`a == d` and `b == c`) - that is, one domino can be rotated to be equal to another domino. Return _th...
dolphin
[ 0.005318686831742525, 0.008102752268314362, -0.029357174411416054, -0.01663862355053425, 0.02926676720380783, 0.0024477122351527214, -0.01955118216574192, 0.0882776528596878, 0.03398677334189415, -0.027813494205474854, 0.01617070846259594, 0.03068227879703045, -0.021001791581511497, -0.017...
0.840374
0.781397
0.058977
"Please focus on the efficiency of this problem and provide code in java:\nGiven a `m x n` `grid` fi(...TRUNCATED)
dolphin
[0.0007047581020742655,0.016773095354437828,-0.03521455079317093,-0.035157665610313416,0.03116976842(...TRUNCATED)
0.840587
0.776286
0.064301
"Please focus on the efficiency of this problem and provide code in Objective-C:\nGiven an unsorted (...TRUNCATED)
dolphin
[0.024620763957500458,0.017792856320738792,-0.03336236625909805,-0.030115636065602303,0.027344599366(...TRUNCATED)
0.840632
0.776444
0.064188
End of preview. Expand in Data Studio
README.md exists but content is empty.
Downloads last month
6