Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Java
  4. Please help me to write a program to simulate a bookstore in java

Please help me to write a program to simulate a bookstore in java

Scheduled Pinned Locked Moved Java
javadesignhelptutorialquestion
5 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    Lost User
    wrote on last edited by
    #1

    Here is the question. Thanks loads... Some of the characteristics of a book are title, author(s), publisher, ISN, price and year of publication. Design the class Book. Each object of the class Book can hold the following information about a book: title, up to four authors, publisher, ISBN, price, and number of copies in stock. To keep track of the number of author add another instance variable. Include the methods to perform various operations on the objects of Book. For example, the usual operations that can be performed on the title are to show title, set the title, and check whether the title is the actual title of the book. Similarly, the typical operations that can be performed on the number of copies in stock are to show the number of copies in stock, set the number of copies in stock, update the number of copies in stock and return the number of copies in stock. Add similar operations for the publisher, ISBN, book price and authors. Add the appropriate constructors. Design a class Member, in which each object of Member can hold the name of a person, member ID, number of books bought and amount spent. Include the methods to perform various operations of the class Member – for example, modify, set and show the person’s name. Similarly update, modify and show the number of books bought and amount spent. Add appropriate constructors. Using the class Book and Member, write a program to simulate a bookstore. The bookstore has two types of customers: those who are members of the bookstore and those who buy books from the book store only occasionally. Each member has to pay RM10 as yearly membership fees and receives a 5% discount on each book bought. For each member, the bookstore keeps track of the number of books bought and the total amount spent. For every eleventh book that a member buys, the bookstore takes the average of the total amount of the last 10 books bought, applies this amount as a discount, and then reset the total amount spent to 0. Write a program that can process up to 100 book titles and 50 members. Your program should contain a menu that gives the user different choices to effectively run the program; in other words, your program should be menu driven. You can use javax.swing for this purpose.

    D 1 Reply Last reply
    0
    • L Lost User

      Here is the question. Thanks loads... Some of the characteristics of a book are title, author(s), publisher, ISN, price and year of publication. Design the class Book. Each object of the class Book can hold the following information about a book: title, up to four authors, publisher, ISBN, price, and number of copies in stock. To keep track of the number of author add another instance variable. Include the methods to perform various operations on the objects of Book. For example, the usual operations that can be performed on the title are to show title, set the title, and check whether the title is the actual title of the book. Similarly, the typical operations that can be performed on the number of copies in stock are to show the number of copies in stock, set the number of copies in stock, update the number of copies in stock and return the number of copies in stock. Add similar operations for the publisher, ISBN, book price and authors. Add the appropriate constructors. Design a class Member, in which each object of Member can hold the name of a person, member ID, number of books bought and amount spent. Include the methods to perform various operations of the class Member – for example, modify, set and show the person’s name. Similarly update, modify and show the number of books bought and amount spent. Add appropriate constructors. Using the class Book and Member, write a program to simulate a bookstore. The bookstore has two types of customers: those who are members of the bookstore and those who buy books from the book store only occasionally. Each member has to pay RM10 as yearly membership fees and receives a 5% discount on each book bought. For each member, the bookstore keeps track of the number of books bought and the total amount spent. For every eleventh book that a member buys, the bookstore takes the average of the total amount of the last 10 books bought, applies this amount as a discount, and then reset the total amount spent to 0. Write a program that can process up to 100 book titles and 50 members. Your program should contain a menu that gives the user different choices to effectively run the program; in other words, your program should be menu driven. You can use javax.swing for this purpose.

      D Offline
      D Offline
      Deresen
      wrote on last edited by
      #2

      No problem, I'll make this for you. You can pay me by paypal, I think $950 USD will be enough for this program. Some people... to lazy to learn at school :thumbsdown:

      L 1 Reply Last reply
      0
      • D Deresen

        No problem, I'll make this for you. You can pay me by paypal, I think $950 USD will be enough for this program. Some people... to lazy to learn at school :thumbsdown:

        L Offline
        L Offline
        Lost User
        wrote on last edited by
        #3

        show me that ur code worth the price... boo...:thumbsdown:

        D 1 Reply Last reply
        0
        • L Lost User

          show me that ur code worth the price... boo...:thumbsdown:

          D Offline
          D Offline
          Deresen
          wrote on last edited by
          #4

          Allright:

          boolean noobIsProgramming = true;

          public void example()
          {
          if(noobIsProgramming)
          {
          destroyComputerIn10Seconds();
          }
          }

          L 1 Reply Last reply
          0
          • D Deresen

            Allright:

            boolean noobIsProgramming = true;

            public void example()
            {
            if(noobIsProgramming)
            {
            destroyComputerIn10Seconds();
            }
            }

            L Offline
            L Offline
            Lost User
            wrote on last edited by
            #5

            wow... good code... congrats... take care...

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups