In a medium saucepan over medium-low heat, cook sugar, butter, egg and dates until dates melt or break down (about 20 minutes). Stir continuously or mixture may burn.
Stir in crisped rice cereal (and walnuts, if adding).
When cool enough to touch but still very warm, pinch off mixture and shape into balls. Roll in coconut, if desired. Let cool completely. Store in airtight container.