static int calculateCommitment(String eventId) { final difficulty = getDifficulty(eventId); return difficulty > 0 ? (1 << difficulty) : 0; }