Category "arrays"

php Keeping only 1 date occurence in multi-dimensional array

I have this array with certain brand_ids, within these brands I have an array of dates in which a sale occured but these are based on the products in sale so th

Can't Print array with multiple data types

I created a struct named products that contains multiple data types: struct products{ int ID; string Name; double Price; int Quantity; }; Then

How to select 3d array elements with another 3-d array of coordinates?

Let's say I have two array, one with all zero elements and the second one with indices that should be filled with 1. This can be done with the following code: A

google sheet : How to find the length of array?

I try to query from other sheet using vlookup() or something similar. I want to count how many array it will produce. How can i find the length of the output or

Loop through an array of strings in Bash?

I want to write a script that loops through 15 strings (array possibly?) Is that possible? Something like: for databaseName in listOfNames then # Do somethi

Issue with getLastRow(), output includes the empty rows as well which I do not want

getLastRow() not working in my script. I am trying to return the last row that has data. But since the spreadsheet has empty rows below the rows filled with dat

Create dynamic sub array from a big one [duplicate]

I have an array, made by using explode and the delimiter #. I'm trying without success to create from this big array in PHP subarrays (the num

I need a function to delete certain characters from a char array in c++ without using any index

for example: if the user enters : ( 23+22+43) I want the function to do exactly the following : for(int i =0; i <strlen(x);i ++) { if (x[i]=='+') {

How to do a get request to SpringBoot java with an Array<Array<string>>?

I am doing a get request in angular with typescript and here it is: this.http.get("http://localhost:8080/data-management/data-users/getAllGeneralInfoCV/"+this.l

Sending Array of files to the server in React

i am trying to send array of files like this to the server but i have a problem it always sent to the server by this format [Object file] how can i send the fil

Filter array by variable in Bot Framework .net

For each item in array1, I want to filter array2 by the array1 item the bot is currently in. Within an Edit an array property, if I filter array2 hard-coded lik

How to sort and remove duplicates from string Array without using the inbuilt function?

I want to remove duplicate string also sort the string array in C# I am reading text file which contains data like Blue, Green, Red, Green, Yellow so I am readi

What is a rich object?

I'm learning Express. While doing a tutorial, I stopped to try to figure out why the tutor used express.urlencoded({extended: false}). I learned what url-encodi

How to make random non-repeating numbers?

I made a code that could generate random numbers, but my issue is that sometimes it would repeat two or three numbers from time to time. int winnum[] = new

Access array in json file in python

Here is a question from an absolute beginner python developer. Here is the challenge I have :) not being able to access the "status" in this json file: [{

Optimized way to implement XOR between floats for huge 2D array data

I need to implement xor between floats in python for huge 2D array data (like thousand row by thousand column matrix). I use the following implementation: impor

Convert String array to an Int array and total it

I need to create a program that accepts input from a file. I need to ask the user to enter two(2) variables, the interest rate and months for the loan. I then c

JSON parse a property of an object inside an object?

I'm trying to JSON.parse(nodeInfluxSeries) a property that is in an object, that is also in an object and in an array. Like so: Array [ Object { "id": 1,

Getting duplicate results from DB

let absent_remove = result_database.filter(item => item.absentday != absent_days) console.log("absent_remove", absent_remove); I got this piece of code, I h

How does the axis parameter from NumPy work?

Can someone explain exactly what the axis parameter in NumPy does? I am terribly confused. I'm trying to use the function myArray.sum(axis=num) At first I t