enhance for loop java
public class Sample { public static void main(String[] args) { String roles[] = { "admin", "customer", "cashier", "manager" }; // for (int x = roles.length - 1; x > -1; x--) { // System.out.println(roles[x]); // } for (String n : roles) { System.out.println(n); } } }