CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 12 of 12
  1. #1
    Join Date
    Dec 2009
    Posts
    3

    Smile Can someone plz help a noob code this program..

    These are the instructions for the program that I must follow. I've never done a program where I had to give the user options to choose from. When I say I am a noob, I really mean it. I figured you guys could probably write this kind of program in your sleep. Thanks very much in advance.

    Write a Java Program that will allow the user to select the option to calculate data for a circle, a rectangle or triangle. The selected output wil be displayed with explanation in the Java output terminal window.

    Create new classes:
    Circle
    Rectangle
    Triangle
    CalculateData (program)

    Accept input from the keyboard using the Scanner class
    User select which geometric shape data will be calculated
    All inputs for calculations must be input by the user

    Use Math.PI in all circle calculations

    Display output using standare output terminal for Java:

    Circle selected:
    Calculate Area
    Calculate Circumference
    Output both radius and diameter

    Rectangle selected:
    Calculate Area
    Calculate parameter
    Output both length and width

    Triangle selected:
    Calculate Area
    Output both base and Altitude

  2. #2
    Join Date
    Apr 2007
    Posts
    425

    Re: Can someone plz help a noob code this program..

    I'll let you know what came out tomorrow after I wake up, although I'm doubtful I am able to write a program in my sleep.
    ------
    If you are satisfied with the responses, add to the user's rep!

  3. #3
    Join Date
    Dec 2009
    Posts
    3

    Re: Can someone plz help a noob code this program..

    That thing I said about writing a program in your sleep was actually meant to be somewhat of a complement, not to be taken literally of course.

  4. #4
    Join Date
    Feb 2008
    Posts
    966

    Re: Can someone plz help a noob code this program..

    Quote Originally Posted by ackerst View Post
    These are the instructions for the program that I must follow.
    Let me show that again so that it sinks in:

    Quote Originally Posted by ackerst View Post
    These are the instructions for the program that I must follow.
    Say it with me: "I will do my own homework."

    Quote Originally Posted by ackerst View Post
    I figured you guys could probably write this kind of program in your sleep.
    While personally I have never tried to actually write code in my sleep, I am fairly certain that the code would look like a monkey banging on the keyboard with its forehead. You know, being as I am asleep and all.

    Quote Originally Posted by ackerst View Post
    Thanks very much in advance.
    No, thank you for the proposal. It's not every day that somebody asks if I would have the pleasure of doing their work for them while they take the credit. Well, not every day at least.

  5. #5
    Join Date
    Dec 2009
    Posts
    3

    Thumbs up Re: Can someone plz help a noob code this program..

    My apologies, I figured nerdy dudes like yourselves get off on doing this kind of stuff. Lets face it, people like yourselves spend all day on these message boards waiting for the next post while you jerk off to the next warcraft expansion and your collection of anime dvds. If I could get you laid I would but having you write a java program was the best I could do. I thought I was doing you a favor. Oh well, no worries, you can go back to leveling up your elf or whatever the hell you have. And just so you know you would not be doing my homework....you mother does my homework along with a few other things. I almost forgot....tell her she needs to get a shot of penicillin asap!!! Tell her I'm sorry, I didn't find out till after I was done with her. Thanks a million bud!!!

  6. #6
    Join Date
    May 2009
    Location
    Lincs, UK
    Posts
    298

    Re: Can someone plz help a noob code this program..

    ... and another one that goes directly to everybody's ignore list.

    Kid, that's not the right attitude when you come here asking for help. To ask someone to write code for you is asking them to do your homework.

    You really made me laugh with your comment:
    I thought I was doing you a favor.
    No, it's the other way around: you are asking for a favour, but then it's normal for children to get confused with this concept.

  7. #7
    Join Date
    May 2002
    Location
    Lindenhurst, NY
    Posts
    867

    Re: Can someone plz help a noob code this program..

    Quote Originally Posted by ProgramThis View Post
    While personally I have never tried to actually write code in my sleep, I am fairly certain that the code would look like a monkey banging on the keyboard with its forehead. You know, being as I am asleep and all.
    I've actually gone to sleep thinking of a design issue or a bug, and, I'd swear, ideas came to me in my sleep that I implemented when I woke up. I could swear this has happened to me a few times.

    Oh @ackerst: You really showed them huh? Good luck with your program

  8. #8
    Join Date
    Jul 2005
    Location
    Currently in Mexico City
    Posts
    568

    Re: Can someone plz help a noob code this program..

    Quote Originally Posted by ackerst View Post
    My apologies, I figured nerdy dudes like yourselves get off on doing this kind of stuff. Lets face it, people like yourselves spend all day on these message boards waiting for the next post while you jerk off to the next warcraft expansion and your collection of anime dvds. If I could get you laid I would but having you write a java program was the best I could do. I thought I was doing you a favor. Oh well, no worries, you can go back to leveling up your elf or whatever the hell you have. And just so you know you would not be doing my homework....you mother does my homework along with a few other things. I almost forgot....tell her she needs to get a shot of penicillin asap!!! Tell her I'm sorry, I didn't find out till after I was done with her. Thanks a million bud!!!
    1. ROFL!!! xDDDD

    2. You're pretty tough guy I see... but don't be shy... carry on... "Nerds" like us don't have time for games and free homework because we are working hard to supply our families and make something out of our lives in this cra**y world, while other awesome guys like Yourself spend their lives thinking with their balls, f***ing all that moves, spending papa's money and drowning in their supreme awesomeness till grave. If you don't change you attitude towards other people, work and life itself you will surely die sooner than you think, and pretty much alone and forgotten. Feel free saying that I sound like your old grandmother, I don't give a sh*t, but you will remember my words before the end.

    3. One of the first rules of this community refers explicitly to asking to help with homework (http://www.codeguru.com/forum/showthread.php?t=366302). I will repeat if you're too lazy to click the link: We are not paid for doing your homework. This is not a "do my homework for me" community. Any help from the forum members is a favor in the name of the art, knowledge, love for work and simple human will to help others.

    4. Anyways the answer you seek is called "Interface", your task is classics and every **** java noobie tutorial website has an example.

    - http://lmgtfy.com/?q=java+interface+tutorial
    Last edited by Xeel; December 8th, 2009 at 05:08 PM.
    Wanna install linux on a vacuum cleaner. Could anyone tell me which distro sucks better?

    I had a nightmare last night. I was dreaming that I’m 64-bit and my blanket is 32-bit and I couldn’t cover myself with it, so I’ve spent the whole night freezing. And in the morning I find that my blanket just had fallen off the bed. =S (from: bash.org.ru)

    //always looking for job opportunities in AU/NZ/US/CA/Europe :P
    willCodeForFood(Arrays.asList("Java","PHP","C++","bash","Assembler","XML","XHTML","CSS","JS","PL/SQL"));

    USE [code] TAGS! Read this FAQ if you are new here. If this post was helpful, please rate it!

  9. #9
    dlorde is offline Elite Member Power Poster
    Join Date
    Aug 1999
    Location
    UK
    Posts
    10,163

    Re: Can someone plz help a noob code this program..

    Quote Originally Posted by Martin O View Post
    I've actually gone to sleep thinking of a design issue or a bug, and, I'd swear, ideas came to me in my sleep that I implemented when I woke up. I could swear this has happened to me a few times.
    Yeah, me too. I now keep a pad and a pencil next to my bed so I can write down solutions to problems that come to me as I fall asleep or wake up. Very useful!

    Any programming problem can be solved by adding a level of indirection...
    Anon.
    Please use [CODE]...your code here...[/CODE] tags when posting code. If you get an error, please post the full error message and stack trace, if present.

  10. #10
    dlorde is offline Elite Member Power Poster
    Join Date
    Aug 1999
    Location
    UK
    Posts
    10,163

    Re: Can someone plz help a noob code this program..

    Quote Originally Posted by ackerst View Post
    My apologies, I figured nerdy dudes like yourselves get off on doing this kind of stuff. Lets face it, people like yourselves spend all day on these message boards waiting for the next post while you jerk off to the next warcraft expansion and your collection of anime dvds. If I could get you laid I would but having you write a java program was the best I could do. I thought I was doing you a favor. Oh well, no worries, you can go back to leveling up your elf or whatever the hell you have. And just so you know you would not be doing my homework....you mother does my homework along with a few other things. I almost forgot....tell her she needs to get a shot of penicillin asap!!! Tell her I'm sorry, I didn't find out till after I was done with her. Thanks a million bud!!!


    ROFL! Reminds me of Rude Kid in Viz magazine!

    Dakin (to Irwin, his teacher): Do you really believe that, sir, or are you just trying to make us think?
    A. Bennet
    Please use [CODE]...your code here...[/CODE] tags when posting code. If you get an error, please post the full error message and stack trace, if present.

  11. #11
    Join Date
    Feb 2008
    Posts
    966

    Re: Can someone plz help a noob code this program..

    Oh this is one of the best childish rants I have seen in a long time. Thank you for the comic relief kid.
    Quote Originally Posted by ackerst View Post
    My apologies, I figured nerdy dudes like yourselves get off on doing this kind of stuff. Lets face it, people like yourselves spend all day on these message boards waiting for the next post while you jerk off to the next warcraft expansion and your collection of anime dvds.
    Really? I thought that I spent all day making 2x what your three dads make in a week. I come here to take a break from looking at my code in order to help impolite jerks like you with yours. For somebody who is calling people nerds, you sure seem to know a lot about this warcraft and anime stuff yourself. Care to tell us about your 'elf'?

    Quote Originally Posted by ackerst View Post
    If I could get you laid I would but having you write a java program was the best I could do.
    Well, I doubt that you could get me laid, but just for the sake of argument lets say that you could. I don't think my wife would like that a whole lot. Well, not unless she could come too

    Quote Originally Posted by ackerst View Post
    And just so you know you would not be doing my homework....you mother does my homework along with a few other things. I almost forgot....tell her she needs to get a shot of penicillin asap!!! Tell her I'm sorry, I didn't find out till after I was done with her. Thanks a million bud!!!
    Ah yes, the classics: mama jokes. I'll try to feel more insulted next time a stranger makes general observations about somebody they have never met.

    Well, good luck next semester retaking this class kid. I'm sure by the second time around you'll be able to write something as simple as this project.

  12. #12
    Join Date
    Apr 2007
    Posts
    425

    Re: Can someone plz help a noob code this program..

    Quote Originally Posted by ackerst View Post
    My apologies, I figured nerdy dudes like yourselves get off on doing this kind of stuff. Lets face it, people like yourselves spend all day on these message boards waiting for the next post while you jerk off to the next warcraft expansion and your collection of anime dvds. If I could get you laid I would but having you write a java program was the best I could do. I thought I was doing you a favor. Oh well, no worries, you can go back to leveling up your elf or whatever the hell you have. And just so you know you would not be doing my homework....you mother does my homework along with a few other things. I almost forgot....tell her she needs to get a shot of penicillin asap!!! Tell her I'm sorry, I didn't find out till after I was done with her. Thanks a million bud!!!
    Aww, did mommy punish you and now you're venting because of the teenage hormones? How cute.

    Let me start off by congratulating you on handing in what will be graded as a 0 assignment no doubt.

    'nerdy' dudes is rather a big misconception. I have a great mind, do a lot of development for my company, get paid a lot, and you know what that allows me to do?

    It allows me to go out and pick up real women, not stupid dim witted girls, indulge in spending on various things that I want, drive a great car, travel, gamble, go to bars, while you sit in your parents basement studying for a degree. The thing is that you haven't realized you won't make it past your first year.

    Grow up and get with reality. We come here when there is a bit of downtime at work.
    ------
    If you are satisfied with the responses, add to the user's rep!

Posting Permissions

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





Click Here to Expand Forum to Full Width

Featured