In reply to dave_59:
But same code will not work in VCS: 2D sum constraint(1) - EDA Playground
The working version for VCS is: 2D sum constraint(2) - EDA Playground
.sum() for multi dimension array is a very useful feature. Hope different simulator can consolidate the syntax.