Skip to main content

Questions tagged [interval]

For code using intervals to measure “distance” between values, possibly as input, output, or in method calls.

3 votes
1 answer
112 views

I have a range of lines in a text file defined by the start and end line number (inclusive) of the range (e.g. (1, 200)). I would like to to exclude some other line ...
Nils's user avatar
  • 131
9 votes
2 answers
658 views

Context I'll be passing an interview coding test in java soon. I am experienced with other programming languages but am very unfamiliar with Java. I am looking for critiques of the coding style much ...
Stef's user avatar
  • 322
2 votes
2 answers
104 views

I'm trying to optimize a function that takes a sorted list of integers and tells me what is the maximum number of elements in the list between any definite size range. To be clear, the range itself ...
Tyler Schuster's user avatar
4 votes
1 answer
106 views

I was recently tasked with creating a function that could generate a "varied" version of some collection of parameters. As in, it should take in a list of parameters, and then vary the value ...
horriblehaskell's user avatar
4 votes
6 answers
721 views

I have a list of (potentially overlapping) ranges, e.g [(3, 9), (8, 10), (1, 18), (1, 1000000)]. I need to process them in order and for each range calculate how ...
Eugene Yarmash's user avatar
6 votes
3 answers
2k views

As already written in the title I want to count the numbers in the range (x+1, y) where x and y are integers, in which the sum of the digits in odd places have the same parity of the ones in even ...
DarkSkull's user avatar
  • 163
2 votes
1 answer
72 views

My Data consists of rows containing a Length/Duration in Minutes, a Begin & EndTime. The precision is 1min (or larger). the table looks something like that: ...
Fritz's user avatar
  • 121
-1 votes
1 answer
373 views

Hi there I was hoping to get a better grasp of greddy algorithms while trying to solve this problem: Hackerrank: Gridland Metro and I was trying to apply an algorithm where each grid could be ...
Elliott de Launay's user avatar
2 votes
1 answer
639 views

I've been assigned the following Python homework: Implement myrange that acts like range using iterators. Define a function ...
bobinthebox's user avatar
3 votes
1 answer
55 views

There is a remote resource containing datasets arranged by time, data is static and doesnt change. Whenever we are going to fetch anything from there we will be saving it in our cache. User might ...
RB_'s user avatar
  • 133
4 votes
2 answers
120 views

Hey I wrote a struct in C++ trying to represent a Pixel Component of a color Here it is ...
Hrant Nurijanyan's user avatar
1 vote
1 answer
2k views

I am writing a script that is supposed to retrieve some data from a MYSQL database but I need to make it happen live and after lots of research I learned that this thing can be done using something ...
Nyx's user avatar
  • 113
3 votes
1 answer
167 views

Problem my code solves: Lack of lightweight numeric range classes which can tell if arbitrary values lie inside them, supporting more than just simple exclusive max modes and integers, and that ...
Krupip's user avatar
  • 926
6 votes
1 answer
112 views

I have unstructured input-output data, f=f(x). I want to estimate the range of f as a function of x, given limited sampled. So, I tried to discretize the data use small bins in x to estimate the ...
kilojoules's user avatar
4 votes
2 answers
223 views

I wrote a simple timestamping filter that prepends each line with the UNIX timestamp in nanosecond precision as returned by clock_gettime, as well as the difference to the previous timestamp. ...
Thure Dührsen's user avatar

15 30 50 per page
1
2 3 4 5
11