Advertisement
Guest User

Untitled

a guest
Feb 21st, 2018
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.96 KB | None | 0 0
  1. class VendingMachine
  2. {
  3.  
  4. private Stack[,] content = new Stack[5,6];
  5.  
  6.  
  7. public VendingMachine()
  8. {
  9. fillUpWares();
  10. run();
  11. }
  12.  
  13. private void firstTimeFillUp()
  14. {
  15. Items myItems = new Items();
  16. int xcount = 0;
  17. int ycount = 0;
  18. foreach (Ware item in myItems.MyWares)
  19. {
  20. if(xcount > 4)
  21. {
  22. xcount = 0;
  23. ycount++;
  24. }
  25. if(ycount < 6)
  26. {
  27. Stack newStack = new Stack(10, item);
  28. content[xcount, ycount] = newStack;
  29. }
  30. }
  31.  
  32. }
  33. private void fillUpWares()
  34. {
  35.  
  36. }
  37. private void run()
  38. {
  39. while (true)
  40. {
  41.  
  42. }
  43. }
  44. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement