I want to know whether it is possible to negate the expression in ballerina like
(not expression)
or
(!expression)
I want to know whether it is possible to negate the expression in ballerina like
(not expression)
or
(!expression)
Yes, you could simply use (!expression).
boolean test = true;
if (!test){
io:println(test);
} else {
io:println(!test);
}