r/javahelp

76K archived posts · Oct 2011 – Sep 2026

Random post

u/HitOrMiss5000•

package c.pkg39;

​

public class C39 {

public static void oof()

{

int everything;

long one = 0;

long two = 0;

long three = 0;

long four = 0;

long five = 0;

long six = 0;

long seven = 0;

long eight = 0;

long nine = 0;

long ten = 0;

long eleven = 0;

long twelve = 0;

long thirteen = 0;

long fourteen = 0;

long fifteen = 0;

long sixteen = 0;

long seventeen = 0;

long eightteen = 0;

long nineteen = 0;

long twenty = 0;

long twentyone = 0;

long twentytwo = 0;

long twentythree = 0;

long twentyfour = 0;

long twentyfive = 0;

long twentysix = 0;

long twentyseven = 0;

long twentyeight = 0;

long twentynine = 0;

long thirty = 0;

long thirtyone = 0;

long thirtyt

277108


u/desrtfx•

From now on, this subreddit does no longer accept lazy posts with unformatted or improperly formatted code.

We have plenty information on the subreddit on how to properly format code that there are absolutely no excuses for not doing so.

You are asking for help, so, spend the minimum effort to produce a proper post.

Code is to be formatted as code block or linked via an external code hoster, like pastebin.com, github gist, github, bitbucket, gitlab, etc.

Code blocks look like this:

public class HelloWorld {

    public static void main(String[] args) {
         System.out.println("Hello World!");
    }
}

See Automoderator's comment below this post fo

1202

u/radulfr2•

The long-awaited new English version of the University of Helsinki Java course has finally been published. It is now equivalent to the current Finnish version which is used as the programming course for the university's computer science students.

Course page: java-programming.mooc.fi
Front page of MOOC (contains other courses as well): mooc.fi/en

Note that while the official support channel is now in Telegram, the original IRC channel (#mooc.fi @ IRCnet) is also still up in case you'd rather use IRC.

9213

u/nutrecht•

Hi! I wanted to point this out because this comes up a LOT in this sub; 'how do I turn my Java program into an executable'. And then we also see a lot of responses from people who try to help, but are not aware of recent additions.

You can find what is in Java 16 here.

The two most important additions I think for people in this sub are records and the packaging tool

Records are mostly just immutable classes that take away most of the fuss of having to write getters, setters, hashcode, equals and toString. More info here.

Jpackage is a tool that lets you take your program and bundle it with a trim

9021


Hi all, 2 days ago i got fired as a Junior Java Developer. The management told me that i am too slow in doing tasks and couldn't do it in deadlines and that even if i have completed them , i made tasks with the help of the team. Additionally i worked there for 2 months. And for two months they draw conclusions about me. Also management told me that my thinking and solving the problems is not appropriate, and i should solve some algorithms in Leetcode and etc. Also they told me that i didn't know some technologies and they gave me 2 days for study it, and told me that they paid me for my study for these 2 days instead of working and solving the problems. So i hope I could tell you the reas

6739


u/alr1ght_•

I've been coding for several months now, and I've acquired a lot of knowledge throughout the way. I've coded many applications, but I never really wrapped one up in order for it to be ready for user execution. I've only tested them in the debugger or in their GUIs, but I don't know how to save user configuration or how to make an application that is ready for use. How do I do that?

6419

u/Royal_Gear1313•

I have been coding since college (B.S. in Electrical Engineering).

I've coded in Python, C#, C++, Java, JavaScript/TypeScript.

No matter what language I use, I always end up coming back to Java.

I want to eventually start my own tech company, and I came to the conclusion that TypeScript/Node.js would be the best thing since I can make a modern UI with react and use Node.js for the backend, so the entire application would be in the same language.

But no matter what, I find myself preferring to code in Java. I definitely have the most work experience with Java, I am a SDET, so I've spent a lot of time creating automation testing frameworks and test data generation t

5936

u/unstopablex5•

Hey so this is probably a really dumb question and I apologize in advance but I'm trying to figure out where Java shines over other languages like C++ and Python.

I had to learn Java during my first programming class in college and I still know the syntax but I could never figure out why I would use Java over another language. If I wanted to make a game or do low level stuff I can just use C++. If I need to do scripting, data science or backend development I can just use python.

Where is Java at its strongest? Why would I choose to build a program in Java?

I tried googling it but the best answer but the best I got was for Android development and because of personal preference. Neither ans

5936

u/pbOmen•

Mods if this isn’t fit for this sub just let me know and I’ll remove (apologies if so)

Hi everyone,

Long time Reddit lurker here. So I’ve been toying with something I get asked a lot in real life which is to do some mentoring.

Firstly let’s be up front this is completely free I just want to give back to some communities which helped me build my career.

To give some some info on me:

I’ve been working in tech for 23 years.

  • I’m the CTO of a scale up
  • I’ve sat on the board of a multinational IPO’d company for the last 3 years
  • I’ve been the head of engineering at another company for the 4 years
  • I’ve held various other managers roles Including head of automation, devOps, performance.
5542

u/AIBackendDev•

I have 2 years of experience as a Java backend developer and had a 30-minute interview today.

The interviewer focused mainly on Core Java (OOP, String immutability, String Pool, etc.), and I realized my fundamentals aren't as strong as they should be. I mean I had read about it but I forgot to speak under pressure.

I also need to prepare backend topics like Spring Boot, Multithreading, Kafka, Docker, Kubernetes, Redis, Linux, and SQL for upcoming interviews.

If you were in my position, how would you structure your preparation? Core Java first, or prepare everything in parallel? Any roadmap or resources would be appreciated.

5226

u/Telas_Toco•

I'm in college and our professor left us a project and it's about recreating a popular video game by implementing data structures and algorithms. Here's the thing, we have to make 'Call of Duty: Black Ops', obviously it won't be the exact game.

My classmates and I want to base it on 'Space Invaders', but you know, change the spaceships for soldiers. Among the requirements is to use Java only, so we have had problems trying to find useful information, but we have not found anything relevant so far.

Does anyone know how the hell I can make soldiers using pixels? It should be noted that we do not have much experience using Java, maybe 4 months... In any case, any recommendation is super val

5231