Page 4 of 4 FirstFirst ... 234
Results 31 to 36 of 36
  1. #31
    vikingTurf Guest

    Re: help me with my homework please!

    While we are at homeworks, does have some experience with openGL??

  2. #32
    FedjeViking is offline Ring of Fame
    Join Date
    Dec 1969
    Posts
    4,159

    Re: help me with my homework please!

    Well it's time to dig up this old thread with school back in session! ;D

    Does anyone know java code using Eclipse? I have to do the Fahrenheit/celisus and visa versa problem. I can get it to work in a string for each, but I need it in a worker class and application class. I'll put in the code I have done and if you can explain how to get the classes stated I would be so happy and grateful!
    ;D

    Code:
     First string
    
    // Conversion
    
    import javax.swing.*; 
    
    public class FtoC{ 
    
    
     public static void main(String[] args)
    
    
     {
    
    
     
     String farenheit =
    
    
     
     
     JOptionPane.showInputDialog("Enter Fahrenheit temperature:" ); 
    
    
     
     double celsius = convert(farenheit);
     
     
    
     
    
    
     
     JOptionPane.showMessageDialog(null,
    
    
     
     
      farenheit +" degree farenheit is equivalent to " + celsius); 
    
    
     
     System.exit(0);
    
    
      
    
    
     }
     
    
    
     public static double convert(String farenheit){
    
    
     
     double temp = Double.parseDouble( farenheit);
    
    
     
     return ( double ) ( 5.0 / 9.0 * ( temp - 32 ) );
    
    
     } 
    
    }
     
    
    Second string:
    
    // Conversion
    
    import javax.swing.*; 
    
    public class Conversion{ 
    
    
     public static void main(String[] args)
    
    
     {
    
    
     
     String celsius =
    
    
     
     
     JOptionPane.showInputDialog("Enter celsius temperature:" ); 
    
    
     
     double farenheit = convert(celsius);
     
     
    
     
    
    
     
     JOptionPane.showMessageDialog(null,
    
    
     
     
      celsius +" degree celsius is equivalent to " + farenheit); 
    
    
     
     System.exit(0);
    
    
      
    
    
     }
     
    
    
     public static double convert(String celsius){
    
    
     
     double temp = Double.parseDouble( celsius);
    
    
     
     return ( double )
     ( temp * 9.0 / 5.0 ) + 32 ;
     
     
      
    
    
     } 
    
    }


    Can't anyone explain how to make a 'Worker class' and an 'Application class' out of these two strings? I'm getting a headache trying to figure it out!
    ;D
    [move]"Our day WILL come!! I just hope I LIVE long enough to see it!"[/move]

  3. #33
    FedjeViking is offline Ring of Fame
    Join Date
    Dec 1969
    Posts
    4,159

    Re: help me with my homework please!

    Can anyone help explain how to do separate classes in Eclipse?? PLEASE! I need to learn this and I don't understand!

    (see above post)
    [move]"Our day WILL come!! I just hope I LIVE long enough to see it!"[/move]

  4. #34
    NordicNed is offline Jersey Retired
    Join Date
    Dec 1969
    Posts
    9,511

    Re: help me with my homework please!


    Fedje,





    What the hell are you talking about?..... ???




    When ever I couldn't get my homework figured out, I just said the DOG ATE IT........



    ;D


    I LOVE THE SMELL OF VICTORY IN THE MORNING AIR.

  5. #35
    FedjeViking is offline Ring of Fame
    Join Date
    Dec 1969
    Posts
    4,159

    Re: help me with my homework please!

    "VikingNed" wrote:

    Fedje,





    What the hell are you talking about?..... ???




    When ever I couldn't get my homework figured out, I just said the DOG ATE IT........



    ;D
    Those days are gone Ned!

    I have to submit it on the computer!

    No excuses either, the college has over 100 to choose from!
    Sucks!

    Someone on this forum HAS to know java!!
    [move]"Our day WILL come!! I just hope I LIVE long enough to see it!"[/move]

  6. #36
    cogitans is offline Jersey Retired
    Join Date
    Jan 2006
    Posts
    6,403

    Re: help me with my homework please!

    I wish I could help you Fedje. I've followed your search for some help here. But I don't know about Java Code or Eclipse.

    Thanks to PPE for the sig.

Page 4 of 4 FirstFirst ... 234

Similar Threads

  1. Always check your kids homework!
    By Garland Greene in forum Two Beer Minimum
    Replies: 19
    Last Post: 02-10-2008, 08:11 AM
  2. Homework Help
    By ViKing24 in forum The Clubhouse
    Replies: 49
    Last Post: 04-26-2007, 11:32 PM
  3. Need Help With Your Homework?
    By ViKing24 in forum The Clubhouse
    Replies: 69
    Last Post: 07-03-2006, 04:45 AM
  4. Vikings' Foley does his homework
    By singersp in forum Vikings Offseason/Draft/FA Forum
    Replies: 7
    Last Post: 02-28-2006, 05:14 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •