LiveWire Peer Support Network

Printable Version of Topic "i need help with JAVA programming..."

- LiveWire Teen Forums & College Forums (http://www.golivewire.com)
-- (http://www.golivewire.com/forums/support-technical.html)
--- Programming & Application Development (http://www.golivewire.com/forums/forum-211-s-0.html)
---- i need help with JAVA programming... (http://www.golivewire.com/forums/peer-iibet-support-a.html)


-- Posted by Iris outsider at 10:08 am on Jan. 22, 2005

i have to write 3 JAVA programs for my computer programming class.....
anyone know the code for writing a mutilpication table????
and how to write a mouse listener method so that the mouse could drag the thing i draw in applet>??
thx a lot....

(Edited by Iris outsider at 12:12 pm on Jan. 22, 2005)


-- Posted by squirellplayingtag at 10:19 am on Jan. 22, 2005

Multiplication table = basic nested for loops.


-- Posted by Iris outsider at 10:22 am on Jan. 22, 2005

i plan to use for loop but dont know how to organize them as a table...
i wrote it before but i forget....


-- Posted by squirellplayingtag at 10:34 am on Jan. 22, 2005

Show me some code and I can help, but I'm not going to do it for you.


-- Posted by Iris outsider at 11:45 am on Jan. 22, 2005

ok

for example i want the program to calculate x+y,where x has increment from 1 to 10,same with y.show the results in table format.
i would do this
for(x=1;x<=10;x++);
 for(y=1;y<=10;y++);
  double result=x+y;
tell me a segment of code to make it in table format.......
thx


-- Posted by squirellplayingtag at 12:07 pm on Jan. 22, 2005

I don't know the swingclass or anything graphical. But I learned.

System.out.print(Format.center(variable,5)
*Required apcslib.Format;


www.golivewire.com