NovaYoshi

cafe menu MUF

Oct 14th, 2021
260
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.94 KB | None | 0 0
  1. lvar output (output string)
  2. lvar menu_prefix
  3. lvar menu_array
  4. lvar menu_count
  5. lvar this_line_items
  6. lvar which_item
  7.  
  8. : add_to_output
  9. output @ "{nl}" strcat swap strcat output !
  10. ;
  11.  
  12. : menu_line ( prefix list count )
  13. menu_count ! menu_array ! menu_prefix !
  14.  
  15. { }list this_line_items !
  16.  
  17. begin
  18. ( get a random index )
  19. srand abs menu_array @ array_count % which_item !
  20.  
  21. menu_array @ which_item @ array_getitem this_line_items @ array_appenditem this_line_items !
  22. menu_array @ which_item @ array_delitem menu_array !
  23.  
  24. menu_count --
  25. menu_count @ 0 =
  26. until
  27.  
  28. menu_prefix @ this_line_items @ ", " array_join strcat add_to_output
  29. ;
  30.  
  31. : main
  32. "%D" systime timefmt setseed
  33. "--- Today's menu ---" output !
  34.  
  35. " Pizzas: cheese, pepperoni, sausage, "
  36. {
  37. "meat lovers" "taco" "deep dish" "mushroom"
  38. "cucumber" "supreme" "sausage & pepperoni"
  39. "Hawaiian" "margherita" "cheese & garlic"
  40. "Chicago style" "vegetable" "Detroit style"
  41. "chicken" "macaroni & cheese" "great" "DiGiorno"
  42. }list 3
  43. menu_line
  44.  
  45. " Main: "
  46. { "cheeseburgers, " "taco bowl, " "sub sandwiches, " "fried chicken, " }list
  47. srand 3 bitand array_getitem strcat
  48. {
  49. "tacos" "stuffed shells" "lasagna"
  50. "ravioli" "chicken nuggets" "chicken strips"
  51. "chicken noodle soup" "chicken parmesan"
  52. "chicken alfredo" "chicken and rice casserole"
  53. "chicken pot pie" "hotdogs" "popcorn chicken"
  54. "green bean casserole" "chili dogs"
  55. "beef stew" "chicken stew"
  56. "lotsa spaghetti" "ravioli"
  57. "beef chili" "cheese manicotti"
  58. "fried lasagna" "corn dogs"
  59. "fried fish" "fish sticks" "cheeseburger casserole"
  60. "pb&j sandwiches" "tater tot casserole"
  61. "grilled cheese sandwich" "pizza bagels"
  62. "chili cheese burgers" "pizza rolls"
  63. }list 5
  64. menu_line
  65.  
  66. " Sides: "
  67. {
  68. "french fries" "curly fries" "steak fries" "waffle fries" "toast"
  69. "potato wedges" "tater tots" "mashed potatoes" "fried pickles"
  70. "macaroni and cheese" "green beans" "carrots" "bread sticks"
  71. "cole slaw" "corn" "biscuits" "hush puppies" "onion rings"
  72. "garlic bread" "loaded potato skins" "apple sauce" "mozzarella sticks"
  73. "nachos" "pretzels" "chips" "pickles" "Doritos" "crackers"
  74. }list 5
  75. menu_line
  76.  
  77. " Fruit: apples, oranges, "
  78. {
  79. "peaches" "strawberries" "bananas"
  80. "blueberries" "raspberries" "cherries" "blackberries"
  81. "kiwifruit" "pineapple" "watermelon" "grapes" "avacados"
  82. "grapefruit" "mango" "papaya" "pears" "pomegranate"
  83. "starfruit" "tangerine"
  84. }list 6
  85. menu_line
  86.  
  87. "Dessert: "
  88. {
  89. "frosted cookies" "chocolate chip cookies" "chocolate cake slice"
  90. "vanilla cake slice" "funnel cake" "jello" "pudding" "donuts" "gummi worms"
  91. "chocolate covered strawberries" "cherry pie" "pumpkin pie" "cheesecake"
  92. "muffin" "cupcake" "brownie" "gingerbread man" "pudding pops" "popsicles"
  93. "fudge popsicles" "Sonic popsicles" "snickerdoodle" "s'mores" "strawberry shortcake"
  94. "chocolate bar" "sprinkle donuts" "ice cream cake" "banana split" "cream pie"
  95. }list 3
  96. menu_line
  97.  
  98. output @
  99. ;
Add Comment
Please, Sign In to add comment