1 Replies - 859 Views - Last Post: 28 October 2012 - 06:42 PM Rate Topic: -----

#1 NewToJava2  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 1
  • Joined: 28-October 12

Using an array to build an address book

Posted 28 October 2012 - 06:38 PM

Hi everybody. I am trying to create an address book in Java using an array and am having a lot of trouble doing so. I am a complete beginner at Java.

Basically I understand that I am going to have two classes. One will store the contact information (Name, Phone, Email) and the other will ask the user to input a name and then access all of that information. I was wondering if you have any tips on how to begin this.....

would it look anything like this?


[public class Friends  {

	public static void main(String[] args) {
        Friend[] friend = new Friend[4];
        friend[0] = new Friend ("Simeon", "Wilcox");
        friend[1] = new Friend ("Simeon", "Wilcox");
        friend[2] = new Friend ("Simeon", "Wilcox");
        friend[3] = new Friend ("Simeon", "Wilcox");



Is This A Good Question/Topic? 0
  • +

Replies To: Using an array to build an address book

#2 pbl  Icon User is offline

  • There is nothing you can't do with a JTable
  • member icon

Reputation: 8342
  • View blog
  • Posts: 31,880
  • Joined: 06-March 08

Re: Using an array to build an address book

Posted 28 October 2012 - 06:42 PM

You will have to show us the code of your class Friend

and I am afraid the post of your class Friends was truncated
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1