Object/class
A Java program and an entire application can be written without creating a single object. Just use the static keyword in front of every method and every field of a class you are creating and call them from the static main() method. You will be limited in your programming capabilities. You will not be able to create an army of objects that can work in parallel doing a similar job on their own copy of data, for example. But your application will still work.
Besides, in Java 8, functional programming features were added that allow us to pass around functions the same way an object can be passed. So, your object-less application could be quite capable. And several languages without object creating capabilities were used very effectively. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access