Delaration of an array with indexed type


#1

Hi,

I found a big problem to declare an array with composite type.

In my code, I would like to write

tuple PM
{
npm::Int64
nvm::String;
}

indexes=PM
push!(indexes,PM(1,“s”))
push!(indexes,PM(2,“s”))
push!(indexes,PM(1,“m”))
push!(indexes,PM(2,“m”))

How could I write ths declaration ?

int countPVX[indexes]; ???


#2

This is not even Julia code?

Neither is this.

Please try to put some effort into formulating your question. See PSA: make it easier to help you.


#3

xref: https://stackoverflow.com/questions/54503339/problem-how-to-declare-an-array-of-composite-type-with-julia