The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
call constructor of java class in script thebladerunner Shell Programming and Scripting 1 10-21-2008 12:23 PM
Linguistic Tree Constructor 2.8.0 (Default branch) iBot Software Releases - RSS News 0 01-27-2008 07:30 PM
how do you handle a constructor and destructor that fail amitpansuria High Level Programming 4 08-16-2007 02:16 PM
what is diff b/w copy constructor and overloaded assignment operator amitpansuria High Level Programming 3 08-06-2007 12:45 PM
why constructor cannot be virtual amitpansuria High Level Programming 2 08-03-2007 12:02 AM

Closed Thread
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 09-05-2006
Registered User
 

Join Date: Sep 2006
Posts: 2
Constructor problem

Hi guys I am new to these forums but since I am taking a class at college I would appreciate any help that is possible for this program. My instructor said that when its complete the program should be able to store all 3 fields instead of just 1.

public class Greeter2Test
{
public static void main( String[] args)
{
Greeter terse = new Greeter ( "Hello, ", "Goodbye, ", "Dave" );
Greeter verbose = new Greeter ("How are you, ", "Have a nice day, ", "Hal");

System.out.println( terse.sayHello() );
System.out.println( verbose.sayHello() );
System.out.println( verbose.sayGoodbye() );
System.out.println( terse.sayGoodbye() );
}
}
Im not sure what it is that I am supposed to edit to make it work properly
The error I get is cannot find symbol. But I cant see which symbol it means or what exactly it is that I am misssing any help would be most appreciated.
Forum Sponsor
  #2  
Old 09-05-2006
aniseed's Avatar
Registered User
 

Join Date: Dec 2005
Location: Mumbai, India
Posts: 23
Quote:
Originally Posted by woot4moo
Hi guys I am new to these forums but since I am taking a class at college I would appreciate any help that is possible for this program. My instructor said that when its complete the program should be able to store all 3 fields instead of just 1.

public class Greeter2Test
{
public static void main( String[] args)
{
Greeter terse = new Greeter ( "Hello, ", "Goodbye, ", "Dave" );
Greeter verbose = new Greeter ("How are you, ", "Have a nice day, ", "Hal");

System.out.println( terse.sayHello() );
System.out.println( verbose.sayHello() );
System.out.println( verbose.sayGoodbye() );
System.out.println( terse.sayGoodbye() );
}
}
Im not sure what it is that I am supposed to edit to make it work properly
The error I get is cannot find symbol. But I cant see which symbol it means or what exactly it is that I am misssing any help would be most appreciated.
I'm not sure what you mean - or what your instructor means. I don't see any place where it is taking a single input. And I don't know what he means by making it take three. You might post what that Greeter class contains.

How, may I also ask, is it related to Unix?
  #3  
Old 09-05-2006
Registered User
 

Join Date: Feb 2006
Posts: 25
Buddy you have missed the Greeter class definition and this question is related to Java.
  #4  
Old 09-05-2006
Registered User
 

Join Date: Sep 2006
Posts: 2
I apologize for being misguided in my previous question and to boot placing it in the wrong forum sorry
  #5  
Old 09-05-2006
Ygor's Avatar
Moderator
 

Join Date: Oct 2003
Location: -31.96,115.84
Posts: 1,249
Thread closed. Reason: Homework.
Google The UNIX and Linux Forums
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 03:21 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0