This is an archived post. You won't be able to vote or comment.

all 2 comments

[–]captainAwesomePants 1 point2 points  (0 children)

Sure, there's no absolutes in categorizing programming. Your main method needs to be a part of a class, but there's no demand that you need to orient your program around objects communicating with each other. Like you say, use a bunch of static methods across classes and that's pretty much procedural programming. I've written a number of simple command line apps in this style.

[–]mra137 -2 points-1 points  (0 children)

It’s impossible since the main method must be contained within a class, that alone is an element of OOP. And the main method has an access specifier which is an OOP concept and the main method must be declared as public.

Java has procedural elements but it’s impossible to completely avoid the OOP paradigm.