A practical number is a natural such that all smaller naturals can be represented as sums of distinct divisors of . For instance, 12 is a practical number, because all numbers from 1 to 11 can be expressed as sums of 1, 2, 3, 4, and 6: , , , , , and .
Given several naturals, are them practical numbers?
Input consists of at most 50 naturals, all between 1 and .
For each given natural, print “yes” or “no”
depending on whether it is a practical number or not.
Author: Salvador Roura
Generation: 2026-01-25T11:42:44.543Z
© Jutge.org, 2006–2026.
https://jutge.org