public class chap7p4 { public static void main(String[] args) { int[] heights = { 33, 45, 23, 43, 48, 32, 35, 46, 48, 39, 41, }; printArray(heights);
Also here argument is of type int, and Operators like(*,+,..) won't work for argument type void and int so either change argument type or return type as mentioned above.