Category "arrays"

Fill treeview from custom array of objects. Recursion call

I'm using treeview to display my hierarchical data. I have following array of objects: const data = [ { id: 1, hierarchyid: "/", level: 0, name: "Mhz" },

Mongoose Schema for Groups (a number of users in one group)

One aspect of my website is that people can join groups according to a specific code provided to them, for example- when we play 'Kahoot' or 'Psych', we have to

Difficulties using ArrayFormula

I am trying to use ArrayFormula to populate row data. I have the following formula that work perfect when I drag down, however I am unable to figure out how I s

How can data from a GET request be displayed in HTML?

When I click on my button, I expect the data from the endpoint to be returned. However, I get this error: Id:undefinedURL:undefinedName:undefinedDescription:und

An array of 5 string is given where each string contains 2 characters, Now you have to sort these strings using insertion sort, like in a dictionary

An array of 5 string is given where each string contains 2 characters, Now you have to sort these strings using insertion sort, like in a dictionary. Input Inpu

Concatenation of array and array element on i'th position

Having some declared types and an array: type player = Orange | Red | Blue | White ;; type piece = Knight of player | Town of player | City of player

Return Elements in the array that start with a specific letter e.g D

I am having issue with my code below. I am new to ruby. I want to return names that only start with the letter D but it just returns all the names. When I try t

How to avoid poorly optimized code for Fortran array pointers?

I get rather poorly optimized assembly with gfortran 11.2 when using array pointers, even in seemingly very simple cases. For example, the optimized code (https

Face detection return value without face

I' using haar cascade for face detection faces_haar = face_cascade.detectMultiScale(image, scaleFactor=1.3, minNeighbors=4, minSize=(30, 30), flags=cv2.CASCADE

With arrays, why is it the case that a[5] == 5[a]?

As Joel points out in Stack Overflow podcast #34, in C Programming Language (aka: K & R), there is mention of this property of arrays in C: a[5] == 5[a] Jo

modifying arrays in C

backstory (if interested): Recently, I have learned to write numbers in binary. So, I wanted to see if I could write every single possibility for 32-bits. So, I

Filling up an empty cell with adjacent cell's value

I am looking for a simple script which can turn this into this As you can see I have manually copied and pasted those empty cells in E column with the corresp

How to convert List<Integer> into JSONArray of Integers, using stream() method in Java

I'm trying to find best way to convert List of Integers to JSONArray of org.json.JSONArray library for API call. For that purpose I'm trying to implement stream

Attempting to 'permanetly' save two user inputs into two seperate arrays, and display the array data in a listbox on a different form

Apologies I am a newbie, ill try to explain as best as I can. Im creating a game for a university assignment. My game is a maths game that asks the user maths q

create a binary file after sorting a numbers with names

I'm trying to wirte a C Program, which sorting list of numbers with names from txt file and write it in a bin file but the problem is that i can't write the bin

Google Sheets Split function with Array

I have a table of current work hours in column A. Column B has newly assigned work hours. Column C just sums up the first two columns to show the new work hours

Cypress won't show an array contents into the console

I'm trying to add the titles of an iframe header into an array to then print the array with it's element into the console. The elements are added just fine, the

Regexextract multiple <a> links from HTML

I have an extract from a description off a webpage which contains multiple links to other pages the whole string is in a single cell. The string below is along

Writing an array to a file in javascript [duplicate]

I have an array of 32 strings called "arr" and I'm trying to save it to a file (like a txt file). I'm doing this in javascript because I'm get

How to create a nested data structure from 2 arrays?

Hi guys I get confused trying to qcheave this, so any help would be great! I have two arrays from which I need a specific object. Source arrays: 1-Types (1D):