for example I want to do something like this:
package tst;
public class forInif {
public static void main(String[] args) {
int[] a = {1,2,3,4,5};
if (for(int i : a) {i == 5;}) {/**/}
}
}
I know normally I should make a boolean value of this situation by my own, but just in case, is there anyway to do something like that rather than make a boolean value somewhere else?