python (12.9k questions)
javascript (9.2k questions)
reactjs (4.7k questions)
java (4.2k questions)
java (4.2k questions)
c# (3.5k questions)
c# (3.5k questions)
html (3.3k questions)
C# problems getting results from List<T> BinarySearch with duplicates in the first and last position
I'm playing around with different implementations for the most simple of the LeetCode problems TwoSums. I have various other ways working fine using methods like indexof, Dictionary searches, brute fo...
cjf-f3
Votes: 0
Answers: 2
Getting a timeout with Big Numbers
I was solving CodeWars task(https://www.codewars.com/kata/5e4bb05b698ef0001e3344bc/train/csharp) and faced a problem. In it you are given the array of numbers, which length is multiply of 4, you need ...
Iceneo
Votes: 0
Answers: 1
Present Sequence as a sum of 2 squares
I was solving a CodeWars task and faced a problem.
In it you are given the array of numbers, which length is a multiple of 4, you need to visualise it as a (x1^2 + x2^2) * (x3^2 + x4^2) .... * (xn^2 +...
Iceneo
Votes: 0
Answers: 1
Binary search program cause runtime error and failed hidden test cases
I am practicing binary search with problem 704 on leetcode. At first, I just follow the concept of binary search and came up with this solution:
int search(int* nums, int numsSize, int target){
si...
Steven
Votes: 0
Answers: 2