Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > I really need help with this so if anyone can help me out that wouldbe really great of you.

Reply
Thread Tools

I really need help with this so if anyone can help me out that wouldbe really great of you.

 
 
adityagaddam90@gmail.com
Guest
Posts: n/a
 
      02-06-2008
I am a student studying in college this is my first year and i am
taking Computer Science as my Major but i am having a hard time with
my course. I have no idea of whats going on in class so if any 1 knows
anything about this things i have to do please help me out.

the professor gave us this to do and i am having some trouble with
this so plz help me out on what to do here.

Part I

Write a program that prints the following pattern:

*
***
*****
*******
*****
***
*

Part II

To make a profit a local store marks up the prices of its items by
25%. Write a Java program that declares the following variables:
1. a double variable named percent_markedup
2. a double variable named original_price
3. a double variable named sales_tax_rate


In your program be sure to assign a value to each of the variables 1-3
above. Use initialization for 1 and 2 and for 3.

Using the information from above, the program should then output:
1. the original price of the item
2. the marked-up percentage of the item (original price times percent
of markup)
3. the store's selling price of the item
4. the sales tax rate
5. the sales tax
6. the final price of the item (the final price of the item is the
selling price plus the sales tax)



can u send me an email or using this to communicate. My email is
http://www.velocityreviews.com/forums/(E-Mail Removed). thx a lot
 
Reply With Quote
 
 
 
 
Patricia Shanahan
Guest
Posts: n/a
 
      02-06-2008
(E-Mail Removed) wrote:
> I am a student studying in college this is my first year and i am
> taking Computer Science as my Major but i am having a hard time with
> my course. I have no idea of whats going on in class so if any 1 knows
> anything about this things i have to do please help me out.
>
> the professor gave us this to do and i am having some trouble with
> this so plz help me out on what to do here.


See http://home.earthlink.net/~patricia_.../beginner.html for my
advice on this situation.

Patricia
 
Reply With Quote
 
 
 
 
Andrew Thompson
Guest
Posts: n/a
 
      02-06-2008
On Feb 6, 10:11*am, (E-Mail Removed) wrote:
> *I am a student studying in college this is my first year and i am
> taking Computer Science as my Major but i am having a hard time with
> my course. I have no idea of whats going on in class so if any 1 knows
> anything about this things i have to do please help me out.
>
> the professor gave us this to do and i am having some trouble with
> this so plz help me out on what to do here.


<http://home.earthlink.net/~patricia_shanahan/beginner.html>

> ...can u send me an email


No this is not a helpdesk, it is a public forum.
And can you please take more effort to spell words fully?

>..or using this to communicate. My email is
> (E-Mail Removed).


'You have spam!' It is best not to post your email
address clearly on the internet, but I suppose for a
GG poster, it makes little difference.

--
Andrew T.
PhySci.org
 
Reply With Quote
 
Mark Space
Guest
Posts: n/a
 
      02-06-2008
(E-Mail Removed) wrote:
> I am a student studying in college this is my first year and i am
> taking Computer Science as my Major but i am having a hard time with
> my course. I have no idea of whats going on in class so if any 1 knows
> anything about this things i have to do please help me out.


I'm just curious: is this your first programming class ever or are you
taking a second or later course now?

Patricia gave pretty good advice. The only things I would add are:

1. Talk to your professor during office hours, or just before or just
after class. You may not be the only one having these problems.

2. Go to your computer lab and ask the assistants. Often, that's why
they are there. If not (they can't or won't help you), try to find out
if there's a lab with assistants who are available for instruction.
 
Reply With Quote
 
Daniel Pitts
Guest
Posts: n/a
 
      02-06-2008
(E-Mail Removed) wrote:
> I am a student studying in college this is my first year and i am
> taking Computer Science as my Major but i am having a hard time with
> my course. I have no idea of whats going on in class so if any 1 knows
> anything about this things i have to do please help me out.
>
> the professor gave us this to do and i am having some trouble with
> this so plz help me out on what to do here.
>

[snip problem descriptions]
>
> can u send me an email or using this to communicate. My email is
> (E-Mail Removed). thx a lot


My suggestion to you is to post what you've already tried, and what went
wrong with it. We won't do your homework for you here, but many of us
will help you understand it and make it happen.

--
Daniel Pitts' Tech Blog: <http://virtualinfinity.net/wordpress/>
 
Reply With Quote
 
adityagaddam90@gmail.com
Guest
Posts: n/a
 
      02-06-2008
On Feb 5, 7:24 pm, Mark Space <(E-Mail Removed)> wrote:
> (E-Mail Removed) wrote:
> > I am a student studying in college this is my first year and i am
> > taking Computer Science as my Major but i am having a hard time with
> > my course. I have no idea of whats going on in class so if any 1 knows
> > anything about this things i have to do please help me out.

>
> I'm just curious: is this your first programming class ever or are you
> taking a second or later course now?
>
> Patricia gave pretty good advice. The only things I would add are:
>
> 1. Talk to your professor during office hours, or just before or just
> after class. You may not be the only one having these problems.
>
> 2. Go to your computer lab and ask the assistants. Often, that's why
> they are there. If not (they can't or won't help you), try to find out
> if there's a lab with assistants who are available for instruction.


yes this is my first programming class ever.
 
Reply With Quote
 
adityagaddam90@gmail.com
Guest
Posts: n/a
 
      02-06-2008
On Feb 5, 8:07 pm, Daniel Pitts
<(E-Mail Removed)> wrote:
> (E-Mail Removed) wrote:
> > I am a student studying in college this is my first year and i am
> > taking Computer Science as my Major but i am having a hard time with
> > my course. I have no idea of whats going on in class so if any 1 knows
> > anything about this things i have to do please help me out.

>
> > the professor gave us this to do and i am having some trouble with
> > this so plz help me out on what to do here.

>
> [snip problem descriptions]
>
>
>
> > can u send me an email or using this to communicate. My email is
> > (E-Mail Removed). thx a lot

>
> My suggestion to you is to post what you've already tried, and what went
> wrong with it. We won't do your homework for you here, but many of us
> will help you understand it and make it happen.
>
> --
> Daniel Pitts' Tech Blog: <http://virtualinfinity.net/wordpress/>


hey Daniel like you have said i tried doing this for part 1 and i
didnt get it right so can u tell me what i have done wrong here.

public class Stars
{
public static void main(string [] args)
{
System.out.println( * );
System.out.println( *** );
System.out.println( ***** );
System.out.println(*******);
System.out.println( ***** );
System.out.println( *** );
System.out.println( * );
}
}
 
Reply With Quote
 
Stefan Ram
Guest
Posts: n/a
 
      02-06-2008
(E-Mail Removed) writes:
> *
> ***
> *****
> *******
> *****
> ***
> *


public class Main
{ public static void main( final java.lang.String[] args )
{ java.lang.System.out.println
( java.lang.String.format
( "%15.0f\n%16.1f\n%17.3f\n%18.5f\n%17.3f\n%16.1f\n% 15.0f\n",
0., 0., 0., 0., 0., 0., 0. ).replaceAll( "\\S", "*" )); }}

*
***
*****
*******
*****
***
*

 
Reply With Quote
 
Patricia Shanahan
Guest
Posts: n/a
 
      02-06-2008
Stefan Ram wrote:
> (E-Mail Removed) writes:
>> *
>> ***
>> *****
>> *******
>> *****
>> ***
>> *

>
> public class Main
> { public static void main( final java.lang.String[] args )
> { java.lang.System.out.println
> ( java.lang.String.format
> ( "%15.0f\n%16.1f\n%17.3f\n%18.5f\n%17.3f\n%16.1f\n% 15.0f\n",
> 0., 0., 0., 0., 0., 0., 0. ).replaceAll( "\\S", "*" )); }}
>
> *
> ***
> *****
> *******
> *****
> ***
> *
>


This seems just a little bit more subtle in its use of advanced features
than I would recommend for the OP's current situation.

Patricia
 
Reply With Quote
 
Patricia Shanahan
Guest
Posts: n/a
 
      02-06-2008
(E-Mail Removed) wrote:
....
> hey Daniel like you have said i tried doing this for part 1 and i
> didnt get it right so can u tell me what i have done wrong here.
>
> public class Stars
> {
> public static void main(string [] args)
> {
> System.out.println( * );
> System.out.println( *** );
> System.out.println( ***** );
> System.out.println(*******);
> System.out.println( ***** );
> System.out.println( *** );
> System.out.println( * );
> }
> }


String literals in Java are enclosed in " marks:

System.out.println("Some string");

Patricia
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
problem in running a basic code in python 3.3.0 that includes HTML file Satabdi Mukherjee Python 1 04-04-2013 07:48 PM
Great Lakes Ruby Bash -- Great Line-Up of Speakers -- RegistrationOpen (Hurry for Lunch!) Eric I. Ruby 0 10-05-2008 06:35 PM
REQ: Cisco 7960 firmware v7.4 - I really need this. Can anyone help? ziigyzigzar Cisco 0 05-26-2005 02:30 AM
Re: CANON - The Great Innovator (was: CANON - The Great Pretender) William Graham Digital Photography 2 08-23-2004 03:17 AM



Advertisments