• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need Ideas for a final program..

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,

I am in CS I, and I'm finally at the end of my programs! WooHoo!
Well, the final program that my teacher has assigned to us looks like quite a doozy to me.
I have to take this list of names which look like this:

Van Zell David # 4 D 4 B#

Store the name into an array list and then string tokenize the line in between the # signs. The number indicates the amount of credits and the letter indicates a grade.
I know I should use something like st.nextToken("#"); to get the stuff in between the # signs, but how do I parse in the number and the letter into two separate things? I have to store these elements into the class itself and not into an array, so I cannot take an array suggestion. Also, I can only have one source code and no other classes weaved into it. What I have to do after I parse these elements is to add the credit hours and then send the letter grades through a switch statement to assign them to a number to get added and then averaged into a GPA. (I know this sounds like one crazy program, eh?)
What I am hoping to find is some suggestions as to where to start with this thing because I have not been having much luck on the web finding information.
So if there is anyone who could give me advise as to where to start with this thing exactly, that would be greatly appreciated.

Thank you!!
 
Rancher
Posts: 600
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Katherine,

Welcome to Java Ranch!

Check out this link, this link, and this link for ideas on how to get started.

John.
 
reply
    Bookmark Topic Watch Topic
  • New Topic