Enum advent_of_code_2021::day_16::PacketType [−][src]
enum PacketType {
Sum,
Product,
Min,
Max,
Literal,
GreaterThan,
LessThan,
Equal,
}Expand description
The eight possible packet types
Variants
Sum
Operation: Sum all contained packets
Product
Operation: Multiply all contained packets
Min
Operation: Return the minimum of all contained packets
Max
Operation: Return the maximum of all contained packets
Literal
Literal: This packet represents a literal number value
GreaterThan
Operation: Compare the first and only two sub packets, returns 1 if first is greater than
second, 0 otherwise.
LessThan
Operation: Compare the first and only two sub packets, returns 1 if first is less than
second, 0 otherwise.
Equal
Operation: Compare the first and only two sub packets, returns 1 if first is equal to
second, 0 otherwise.
