Constraint for row total with each element in the array less than a given value

You need to wirte two seperate constraints for element less than 80, and sum of row equal to 100.
Try this:


constraint abc{foreach(array[i]){
  foreach(array[i,j]){
    array[i][j] < 80;
}
}
}
constraint def{foreach(array[i]){
  array[i].sum(item) with (int'(item))==100;}}