Still not working how I want it to

Java is different enough C that I'm having some trouble translating the
original program, working how I would like it to