Where to store my pizza? Answer: In a delicious database!
Working on a simple Java program for ordering pizza and could use some direction on storing the orders. My program loads a menu, asks for a name, prompts user for pizza values (crust size, toppings, etc.), passes those values to a constructor that creates the pizza, tracks the number of pizzas made, assigns order numbers, and gives user option to create new order (Y/N, with 'Y' running through the creation process again and 'N' exiting program). There are static fields that increment and track number of pizzas made but as soon as the user exits the program the counter resets to zero. I'm still learning Java, so my IO and database skills are limited. Wondering if I can/should write the orders to a text file, then maybe read from file to set/adjust my static counter fields when the program starts again? Hope this makes sense. Again, don't really have code to share, just in need of a little direction to explore solutions. Thanks 😊