scoreboard players set min times_appeared 0

execute if score #holy_water shop matches 1 if score min times_appeared matches -1 run scoreboard players operation min times_appeared = holy_water times_appeared
execute if score #holy_water shop matches 1 if score holy_water times_appeared < min times_appeared run scoreboard players operation min times_appeared = holy_water times_appeared

execute if score #tornado shop matches 1 if score min times_appeared matches -1 run scoreboard players operation min times_appeared = tornado times_appeared
execute if score #tornado shop matches 1 if score tornado times_appeared < min times_appeared run scoreboard players operation min times_appeared = tornado times_appeared

execute if score #mini_sun shop matches 1 if score min times_appeared matches -1 run scoreboard players operation min times_appeared = mini_sun times_appeared
execute if score #mini_sun shop matches 1 if score mini_sun times_appeared < min times_appeared run scoreboard players operation min times_appeared = mini_sun times_appeared

execute if score #void_tear shop matches 1 if score min times_appeared matches -1 run scoreboard players operation min times_appeared = void_tear times_appeared
execute if score #void_tear shop matches 1 if score void_tear times_appeared < min times_appeared run scoreboard players operation min times_appeared = void_tear times_appeared

execute if score #chickifier shop matches 1 if score min times_appeared matches -1 run scoreboard players operation min times_appeared = chickifier times_appeared
execute if score #chickifier shop matches 1 if score chickifier times_appeared < min times_appeared run scoreboard players operation min times_appeared = chickifier times_appeared

execute if score #zeus_discharge shop matches 1 if score min times_appeared matches -1 run scoreboard players operation min times_appeared = zeus_discharge times_appeared
execute if score #zeus_discharge shop matches 1 if score zeus_discharge times_appeared < min times_appeared run scoreboard players operation min times_appeared = zeus_discharge times_appeared
execute if score min times_appeared matches -1 run scoreboard players set min times_appeared 0