#K83512. Fishing Rod Weights
Fishing Rod Weights
Fishing Rod Weights
You are given three integers A, B, and C representing the weight capacities of three friends. Each friend prefers a fishing rod whose weight does not exceed their capacity. The rods are to be assigned such that the weight of the rod each friend carries is exactly equal to their capacity. However, this assignment is only valid if the capacities are in strictly descending order, i.e. in mathematical terms, if and only if \(A > B > C\).
If the condition \(A > B > C\) is satisfied, output the rod weights \(A\), \(B\), and \(C\) (in that same order). Otherwise, output -1
.
inputFormat
The input is provided via standard input and consists of a single line containing three space-separated integers: A, B, and C.
outputFormat
If the condition \(A > B > C\) holds, print a single line with the three integers \(A\), \(B\), and \(C\) separated by spaces. Otherwise, print -1
.
60 40 20
60 40 20