• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

NaturalLanguageMultiply extends Say ?

 
Greg Harris
Ranch Hand
Posts: 1012
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
am i the only one that has tried this? ever since i wrote NaturalLanguageMultiply i have been wondering how easy it would be to make it extend my Say (4b) class so i could have the output in "natural language" as well...
it just so happens that the first method in my Say class takes a String as an argument... so, i made my NatualLanguageMultiply extend Say and then i just called the method with my multiplied value (converted to a String)!
anyway, i am just wondering if i am the only person who has tried this... (i hope not, that would mean i am obsessed )
 
Johannes de Jong
tumbleweed
Bartender
Posts: 5089
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As far as I'm concerned you are obsessed
To be honest though my son did suggest that I let NaturalLanguageMultiply say its result but I was just to damm lazy.
 
Greg Harris
Ranch Hand
Posts: 1012
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
haha... so i am thinking like your son. i don't know what to say to that.
actually, this could be a good introductory program for the OO school...
 
Michael Matola
whippersnapper
Ranch Hand
Posts: 1797
4
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A fun thing to write would be the "if this is tea, bring me coffee; if this is coffee, bring me tea" version.
For example, pass in "17" and get "seventeen" as the result. Pass in "seventeen" and get "17" as the result.
If you're writing this as some number conversion library class, I'm sure you'd want different methods based on which direction you're converting. But if you're doing it as an exercise, it might be fun to let the program figure out whether the input is text or a figure.
 
Greg Harris
Ranch Hand
Posts: 1012
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
great, i thought i was going to stay away from programming this weekend... now i have to write this! thanks, michael.
 
Michael Matola
whippersnapper
Ranch Hand
Posts: 1797
4
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In case you're looking for other things to work on...
Nobody's posted a response to my "challenge" regarding adding new validation functionality to the assignment log automation prototype.
 
Richard Boren
Ranch Hand
Posts: 233
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You are obsessed . But, what a way of looking at the assignment.
 
Greg Harris
Ranch Hand
Posts: 1012
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
michael, i have an idea for the color part... i modified a bulletin board servlet a couple weeks ago so the font changes based on the username. it would be really easy to implement that based on the days since last submission. making it change the background vs. the text font is a no brainer.
[This message has been edited by Greg Harris (edited August 15, 2001).]
 
Johannes de Jong
tumbleweed
Bartender
Posts: 5089
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Michael Matola:
In case you're looking for other things to work on...
Nobody's posted a response to my "challenge" regarding adding new validation functionality to the assignment log automation prototype.


 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic