aspose file tools
The moose likes Beginning Java and the fly likes Personality Program Percentage Problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Personality Program Percentage Problem" Watch "Personality Program Percentage Problem" New topic

Personality Program Percentage Problem

Laura Peterson

Joined: Mar 14, 2013
Posts: 23

I'm working on a problem that processes an input file of data for a personality test known as the Keirsey Temperament Sorter. ( for more info) After I get my checkpoint output (which is correct according to my test data), I need to compute and output a second file with the percentage of "B" answers. This is where I get lost- any advice, references, or helpful hints would be welcome.
I've included a link with the instructions for the problem, since they're particularly complicated.
And for those concerned, this is NOT a homework problem, merely an extra credit opportunity for anyone who wants to try a challenge. (I have a 97% in the class, but I need the programming practice.)
Thank you!

Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14666

Welcome to the Ranch.

Can you be a bit more specific about what you are lost about?

The count method in your code looks awfully complicated. It's not clear at all what exactly it does.

Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 8 API documentation
Campbell Ritchie

Joined: Oct 13, 2005
Posts: 41576
Welcome again
Why have you got so many static methods? That suggests you are not using object‑oriented programming.
Laura Peterson

Joined: Mar 14, 2013
Posts: 23

In response to your questions... I'm lost as to how to get the percentage of the answer B from the information sorted in the method count. What I have doesn't really do anything, and I'm not sure what more to do.
We haven't gotten into OOP yet. We've covered expressions, loops, strings, arrays, scanner- pretty much it. We'll be doing classes next, I imagine.
Thank you!
I agree. Here's the link:
subject: Personality Program Percentage Problem