Since there are solely about 28.3 grams per ounce, 40 grams would
not get anyplace close to a cup. It will be roughly 1-1/3
ounces, which measures out at about 2 tablespoons and 1 teaspoon.
Please notice these are American measurements; Imperial measurements
would differ from this barely.