I get a compilation error while trying to compile, \"not a statement\", and the code is:
(checkDatabaseExist())?connectToDB() : buildDB();
when
The ternary operator can not be used with methods/operations returning void.
The methods/expressions must return a value compatible with the reference type.