Jump to content

Hi, I have to do this assignment and I honestly don't know what to do... people have tried helping me in the past but I really can't do it. Can someone do this assignment for me? I know most people don't like just writing the program and they would rather show me the right direction... but I would really appreciate if you could just do it this one time. If not, no problem I totally understand why you wouldn't want to. Otherwise, thank you so much!

 

This is the assignment:

 

Congratulations, you have just become Java TV's newest owner! Java TV is the greatest TV channel ever, and it prides itself in its 24 hour interesting ' programming'. To help you run this channel you will need to write a dynamic program that uses Data Lists to store all its TV show information.

 

Your program will contain the following Menu Options:

 

Enter TV Shows/Add a TV Show: This option should allow the user to enter as many shows as he wants, your program should always keep track of how many shows the user has entered.

 

Modify TV Show: This option should ask the user what show he would like to modify and search for it using the name of the show as the search key. The user should be able to modify that show information.

 

Delete TV Show: Like the Modify option, the delete option searches for a show using the show's name. Once found the show should be removed by shifting the array one space. 
(Example: to delete array position 4, 5->4, 6->5,7->6...and so on)

 

Sort TV Shows: The sort function asks the user what sort key he would like to use (name, day, time) and sorts the list using that key.
Note: The sort by day will sort alphabetically, that is fine, see the Bonus for a proper day sort.

 

Show all TV Shows: This option outputs all the shows and also gives totals for the number of shows per day.

 

Exit: This will quit the program.

 

BONUS: add the following Menu Options:

 

 

Save TV Shows: This should save your arrays to a file named "TV.txt", Don't forget to add a header that says how many TV shows are in the file.

 

Load TV Shows: This should load the TV Shows from "TV.txt", you will need to read the header first to see how many Shows are in the file.

Link to comment
https://linustechtips.com/topic/180454-java-help-please/
Share on other sites

Link to post
Share on other sites

We're not going to do your homework for you. If you can't complete it, admit it to your professor and find a tutor to help you.

"You have got to be the biggest asshole on this forum..."

-GingerbreadPK

sudo rm -rf /

Link to comment
https://linustechtips.com/topic/180454-java-help-please/#findComment-2423473
Share on other sites

Link to post
Share on other sites

It's a call for help right? You don't want to fail and you'll do anything you can to prevent that. You probably have three options left since you have already gotten a feel for how your question is being received so far. Before you go down any of those paths, may I see if I can give you a little push?

 

Lets firstly de-construct some of the main things that are being asked of you:

  • It looks like they want you to demonstrate SCRUD (Search, Create, Read, Update and Delete).
  • Going on the wording (and this used to irritate me to no ends when given an assignment) it looks like they also want you to demonstrate that you know how to work with basic arrays. Reading this part: "...write a dynamic program that uses Data Lists to store all its TV show information." one could have assumed it being acceptable to use a generic list which would have done some of the heavy lifting for you. But alas as we read further into the delete specification we find: "...by shifting the array one space.(Example: to delete array position 4, 5->4, 6->5,7->6...and so on)" so no, do not use a generic list, use an array.
  • They want you to demonstrate sorting, maybe SO might have some suggestions?  :) Also take a look at this and this and this. Now it may be that like the generic list you're not permitted to use these and instead they want you to demonstrate that you can do it yourself. You might want to seek clarification on that.
  • They want you to demonstrate serialization to and from file. Java has an interface for doing this in a basic way.

Now for architecture:

Ask yourself what are our things here? Well we need some kind of collection and something to live in that collection which will represent our data. We also want to glue it all together in the form of some kind of user interface.

 

If it were me, I would make a class to represent TV Shows, into this I would put fields to represent things about the TV Show; their name, day, time and so on. My collection would then contain these TV Show objects. From there I could implement my Comparators for performing sorting and extend my TV Show so that it can implement serialization.

 

I would also be thinking in terms of Model, View, Controller or Model, View, ViewModel; all this simply means is that your model (collection of objects) is kept separate from your controller (the actual logic that operates on it such as sorting for example) and this in tern is kept separate from your view (the user interface). Don't pollute each piece with code from the other (i.e the view shouldn't need to care about the model). Don't worry if this doesn't make sense right now, they probably aren't looking for this; I mention it to you now as only more of a thought exercise when planning the architecture.

 

In conclusion

The information is out there to be had. I know it's easy to give in to panic and enter a spiral where your own mind becomes the enemy. Try to stay calm and concise and look to break the specification down into small manageable chunks of work.

The single biggest problem in communication is the illusion that it has taken place.

Link to comment
https://linustechtips.com/topic/180454-java-help-please/#findComment-2425269
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×