How to assign multidimensional array with default value in systemverilog

In reply to Jacky40210:

You need to specify the default for both dimensions:


rand int A[string][int] = '{default : '{default : -1}};

1 Like