import java.util.Scanner;
public class Name
{
String lastName;
String firstName;
Scanner scan = new Scanner(System.in);
public Name(String LastName, String FirstName)
{
lastName = LastName;
firstName =FirstName;
};
public String getFirstName()
{
return firstName;
}
public void setFirstName (String FirstName)
{
firstName = FirstName;
}
public String getLastName()
{
return lastName;
}
public void setLastName (String LastName)
{
lastName = LastName;
}
public String toString()
{
String name = ("name: " + this.getLastName()+ ", " +this.getFirstName());
return name;
}
}
ChevaneHeadChefCooke 0 Newbie Poster
ChevaneHeadChefCooke 0 Newbie Poster
tux4life 2,072 Postaholic
stultuske 1,116 Posting Maven Featured Poster
IIM 163 Master Poster
stultuske 1,116 Posting Maven Featured Poster
tux4life 2,072 Postaholic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.