Skip to main content
OverflowAI is here! AI power for your Stack Overflow for Teams knowledge community. Learn more

All Questions

Filter by
Sorted by
Tagged with
3 votes
4 answers
1k views

Merging sorted integer arrays (without duplicates)

I have written a Python function called merge_arrays which takes two lists and returns the new list merge without duplicate. The function works as expected, but my ...
XMehdi01's user avatar
  • 523
2 votes
1 answer
124 views

Recursive Factorial Calculation in JavaScript

...
XMehdi01's user avatar
  • 523
3 votes
1 answer
73 views

Dyalog APL dyadic operator deriving ambivalent function to pair two function results

I'm writing a small utility operator which applies two functions to an argument pair and strands the results. The pair can either be given as two arguments or as a single argument with two elements. ...
Adám's user avatar
  • 656
1 vote
1 answer
52 views

Optimizing the Dig Pow function

I have written a Python function to solve the Dig Pow problem, where the goal is to find a number k such that the sum of each digit of n raised to a specific and ...
XMehdi01's user avatar
  • 523
1 vote
1 answer
113 views

Transform an array into object and set index for an unique key in javascript

I have a method that merges keys and indexes from an array into an object. I'm stuck with ways to compress this method, and I don't know what I can do to make it simpler. Goal get an array of objects ...
wittgenstein's user avatar
1 vote
2 answers
199 views

Simplify a function which performs manipulation of data in Javascript

Upon suggestion in the original question within Stack Overflow, I'm bringing my question here. We have created a function that will convert the data into the desired format, but it has a lot of code ...
SDK's user avatar
  • 113
1 vote
1 answer
297 views

Suggestions for improvement for generic array and map functions in Go 1.18

Yesterday I build some generic functions for the new official Golang 1.18 release. What do you think about it and what could be added and improved? ...
Erik Bent's user avatar
11 votes
4 answers
3k views

Restructuring JSON to create a new JSON where properties are grouped according to similar values

I have a JSON structure in the following example format: ...
fruitlessartery's user avatar
0 votes
2 answers
79 views

Functional Programming Style in Javascript Picking a Random Item from an Array

I'm trying to understand the Functional Programming Paradigm (or style) implemented with Javascript. There are a few things I have difficulties with. The naming conventions, and dependency injections. ...
Melvin Idema's user avatar
1 vote
1 answer
101 views

JavaScript, looping, and functional approach

Data Structure coming back from the server ...
FNMT8L9IN82's user avatar
6 votes
3 answers
1k views

Finding even or odd numbers

I'm looking for critiques to see what I could have done better or different ways I could approach writing a script for finding even or odd numbers. I am new to programming with JavaScript, and ...
fire_hydrant's user avatar
13 votes
5 answers
3k views

Vue.js search functionality

In my BlogList.vue component I made a search input field: ...
meez's user avatar
  • 241
0 votes
1 answer
45 views

converting object of arrays to an array of objects in a desired format

...
Vignesh Sharma's user avatar
0 votes
3 answers
278 views

Finding nth lowest value without any Math max or min methods

So I decided to make a more efficient solution to a Google interview question where they ask you to either find the lowest or second lowest value in an array without using the max or min methods. I ...
DreamVision2017's user avatar
4 votes
2 answers
438 views

Replace array element with multiplication of neighbors in Scala

Given an array of integers, update the index with multiplication of previous and next integers, Input: 2 , 3, 4, 5, 6 Output: 2*3, 2*4, 3*5, 4*6, 5*6 Following ...
vikrant's user avatar
  • 385

15 30 50 per page